Interface PaymentAccessValidationService
- All Known Implementing Classes:
DefaultPaymentAccessValidationService
public interface PaymentAccessValidationService
Validates access to the payment based on passed in context.
-
Method Summary
Modifier and TypeMethodDescriptiondefault voidvalidateCustomerPaymentRequest(Payment payment, CustomerRef customerRef, UpdatePaymentRequest updatePaymentRequest, String lockToken, com.broadleafcommerce.data.tracking.core.context.ContextInfo context) Validates access to the payment based on the passed in context.voidvalidateCustomerPaymentRequest(Payment payment, CustomerRef customerRef, String lockToken, com.broadleafcommerce.data.tracking.core.context.ContextInfo context) Validates access to the payment based on the passed in context
-
Method Details
-
validateCustomerPaymentRequest
void validateCustomerPaymentRequest(Payment payment, CustomerRef customerRef, @Nullable String lockToken, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo context) Validates access to the payment based on the passed in context- Parameters:
payment- thePaymentrequiring accesscustomerRef- theCustomerRefto validate againstlockToken- the current lock tokencontext- context information surrounding multitenant state- Throws:
PaymentManagementAccessException- if the request is blocked
-
validateCustomerPaymentRequest
default void validateCustomerPaymentRequest(Payment payment, CustomerRef customerRef, UpdatePaymentRequest updatePaymentRequest, @Nullable String lockToken, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo context) Validates access to the payment based on the passed in context. In the case of aPaymentupdate request, the details of theUpdatePaymentRequestcan be factored into determining if the customer's request should be allowed or blocked- Parameters:
payment- thePaymentrequiring accesscustomerRef- theCustomerRefto validate againstupdatePaymentRequest- the request payload related to an update request (only present for update requests)lockToken- the current lock tokencontext- context information surrounding multitenant state- Throws:
PaymentManagementAccessException- if the request is blocked
-