Class DefaultPaymentResponseUtil
java.lang.Object
com.broadleafcommerce.paymentgateway.util.DefaultPaymentResponseUtil
- All Implemented Interfaces:
PaymentResponseUtil
-
Constructor Summary
ConstructorsConstructorDescriptionDefaultPaymentResponseUtil(com.broadleafcommerce.common.extension.TypeFactory typeFactory) -
Method Summary
Modifier and TypeMethodDescriptionbuildInitialPaymentResponse(@NonNull GatewayTransactionResponse transactionResponse, @NonNull PaymentGatewayType gatewayType) Builds and populates aPaymentResponsebased on the providedGatewayTransactionResponseandPaymentGatewayTypebuildPaymentResponse(@NonNull PaymentRequest paymentRequest, @NonNull PaymentGatewayType gatewayType, @NonNull TransactionType transactionType) Builds and populates aPaymentResponsebased on the providedPaymentRequestprotected com.broadleafcommerce.common.extension.TypeFactoryprotected PaymentResponsepopulateBillTo(@NonNull PaymentResponse paymentResponse, @NonNull Address<?> requestBillTo) protected PaymentResponsepopulateCustomer(@NonNull PaymentResponse paymentResponse, @NonNull GatewayCustomer<?> requestCustomer) protected PaymentResponsepopulateShipTo(@NonNull PaymentResponse paymentResponse, @NonNull Address<?> requestShipTo)
-
Constructor Details
-
DefaultPaymentResponseUtil
public DefaultPaymentResponseUtil(com.broadleafcommerce.common.extension.TypeFactory typeFactory)
-
-
Method Details
-
buildPaymentResponse
public PaymentResponse buildPaymentResponse(@NonNull @NonNull PaymentRequest paymentRequest, @NonNull @NonNull PaymentGatewayType gatewayType, @NonNull @NonNull TransactionType transactionType) Description copied from interface:PaymentResponseUtilBuilds and populates aPaymentResponsebased on the providedPaymentRequest- Specified by:
buildPaymentResponsein interfacePaymentResponseUtil- Parameters:
paymentRequest- the PaymentRequest used to initiate the related transactiongatewayType- the type of gateway used to execute the transactiontransactionType- the type of transaction that was executed- Returns:
- a PaymentResponse populated based on the provided PaymentRequest
-
buildInitialPaymentResponse
public PaymentResponse buildInitialPaymentResponse(@NonNull @NonNull GatewayTransactionResponse transactionResponse, @NonNull @NonNull PaymentGatewayType gatewayType) Description copied from interface:PaymentResponseUtilBuilds and populates aPaymentResponsebased on the providedGatewayTransactionResponseandPaymentGatewayType- Specified by:
buildInitialPaymentResponsein interfacePaymentResponseUtil- Parameters:
transactionResponse- the GatewayTransactionResponse used to create the related transactiongatewayType- the type of gateway used to execute the transaction- Returns:
- a PaymentResponse populated based on the provided GatewayTransactionResponse and Payment
-
populateCustomer
protected PaymentResponse populateCustomer(@NonNull @NonNull PaymentResponse paymentResponse, @NonNull @NonNull GatewayCustomer<?> requestCustomer) -
populateBillTo
protected PaymentResponse populateBillTo(@NonNull @NonNull PaymentResponse paymentResponse, @NonNull @NonNull Address<?> requestBillTo) -
populateShipTo
protected PaymentResponse populateShipTo(@NonNull @NonNull PaymentResponse paymentResponse, @NonNull @NonNull Address<?> requestShipTo) -
getTypeFactory
protected com.broadleafcommerce.common.extension.TypeFactory getTypeFactory()
-