Class PaymentAccountProcessingRequest
java.lang.Object
com.broadleafcommerce.billing.job.domain.PaymentAccountProcessingRequest
- All Implemented Interfaces:
Serializable
This DTO stores the payment account, the payment transaction's processing status, and its result.
This DTO is stored on BillingProcessingRequest
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionPaymentAccountProcessingRequest(PaymentAccount paymentAccount, String paymentProcessor, String transactionReferenceId, PaymentAccountProcessingTransactionType transactionType, Date dateProcessed, PaymentAccountProcessingStatusEnum status, PaymentAccountProcessingResultEnum processingResult, String rawResponse, String failureReason, PaymentFailureTypeEnum failureType, String failureCategory, int gatewayErrorCount, boolean eligibleForGatewayErrorRetries, Map<String, String> transactionAdditionalFields, boolean resultHandled, String billingEventPaymentIdToRefund) -
Method Summary
Modifier and TypeMethodDescriptionvoidaddTransactionAdditionalField(@NonNull String key, @NonNull String value) voidaddTransactionAdditionalFields(@NonNull Map<String, String> additionalFields) protected booleanconvert(org.modelmapper.spi.MappingContext<?, ?> context) booleanBillingEventPaymentId of the RefundEventDetailThe date and time this transaction was sent to the processorA simple categorization of the failure that was encountered while attempting the transaction.Reason for the transaction failureDescribes the severity of the failure.intThe number of times a gateway errors occurred while processing this account.The PaymentAccount associated to this requestCode for the payment processor used for the transaction.The result of this payment processing request.The raw response from the payment processorDeprecated, for removal: This API element is subject to removal in a future version.The status of this account processing request.getTransactionAdditionalField(@NonNull String key) Name/Value pairs of additional attributes.This unique value is used by the processor to rule out the duplicatesTransaction type of the transactioninthashCode()booleanDeclares whether this request is eligible to retry executing the transaction in the case of a gateway error.booleanIndicates that this account result has been handled by the payment result handler.voidsetBillingEventPaymentIdToRefund(String billingEventPaymentIdToRefund) BillingEventPaymentId of the RefundEventDetailvoidsetDateProcessed(Date dateProcessed) The date and time this transaction was sent to the processorvoidsetEligibleForGatewayErrorRetries(boolean eligibleForGatewayErrorRetries) Declares whether this request is eligible to retry executing the transaction in the case of a gateway error.voidsetFailureCategory(String failureCategory) A simple categorization of the failure that was encountered while attempting the transaction.voidsetFailureReason(String failureReason) Reason for the transaction failurevoidsetFailureType(PaymentFailureTypeEnum failureType) Describes the severity of the failure.voidsetGatewayErrorCount(int gatewayErrorCount) The number of times a gateway errors occurred while processing this account.voidsetPaymentAccount(PaymentAccount paymentAccount) The PaymentAccount associated to this requestvoidsetPaymentProcessor(String paymentProcessor) Code for the payment processor used for the transaction.voidsetProcessingResult(PaymentAccountProcessingResultEnum processingResult) The result of this payment processing request.voidsetRawResponse(String rawResponse) The raw response from the payment processorvoidsetRefundEventDetailEventPaymentId(String refundEventDetailEventPaymentId) Deprecated, for removal: This API element is subject to removal in a future version.in favor ofsetBillingEventPaymentIdToRefund(String)voidsetResultHandled(boolean resultHandled) Indicates that this account result has been handled by the payment result handler.voidThe status of this account processing request.voidsetTransactionAdditionalFields(Map<String, String> transactionAdditionalFields) Name/Value pairs of additional attributes.voidsetTransactionReferenceId(String transactionReferenceId) This unique value is used by the processor to rule out the duplicatesvoidsetTransactionType(PaymentAccountProcessingTransactionType transactionType) Transaction type of the transactiontoString()
-
Constructor Details
-
PaymentAccountProcessingRequest
public PaymentAccountProcessingRequest() -
PaymentAccountProcessingRequest
public PaymentAccountProcessingRequest(PaymentAccount paymentAccount, String paymentProcessor, String transactionReferenceId, PaymentAccountProcessingTransactionType transactionType, Date dateProcessed, PaymentAccountProcessingStatusEnum status, PaymentAccountProcessingResultEnum processingResult, String rawResponse, String failureReason, PaymentFailureTypeEnum failureType, String failureCategory, int gatewayErrorCount, boolean eligibleForGatewayErrorRetries, Map<String, String> transactionAdditionalFields, boolean resultHandled, String billingEventPaymentIdToRefund)
-
-
Method Details
-
addTransactionAdditionalField
-
addTransactionAdditionalFields
-
getTransactionAdditionalField
-
getRefundEventDetailEventPaymentId
Deprecated, for removal: This API element is subject to removal in a future version.in favor ofgetBillingEventPaymentIdToRefund()- Returns:
- the BillingEventPaymentId of the RefundEventDetail
-
setRefundEventDetailEventPaymentId
@Deprecated(since="1.0.0", forRemoval=true) public void setRefundEventDetailEventPaymentId(String refundEventDetailEventPaymentId) Deprecated, for removal: This API element is subject to removal in a future version.in favor ofsetBillingEventPaymentIdToRefund(String) -
convert
-
getPaymentAccount
The PaymentAccount associated to this request -
getPaymentProcessor
Code for the payment processor used for the transaction. Ex: CYBERSOURCE, PAYPAL -
getTransactionReferenceId
This unique value is used by the processor to rule out the duplicates -
getTransactionType
Transaction type of the transaction- See Also:
-
getDateProcessed
The date and time this transaction was sent to the processor -
getStatus
The status of this account processing request. -
getProcessingResult
The result of this payment processing request. -
getRawResponse
The raw response from the payment processor -
getFailureReason
Reason for the transaction failure -
getFailureType
Describes the severity of the failure.PaymentFailureTypeEnum.HARD_FAILUREdescribes a failure where the payment method can no longer be used (e.g. card stolen), whereasPaymentFailureTypeEnum.SOFT_FAILUREdescribes a failure where transactions with the payment method can be attempted in the future (e.g. insufficient funds) -
getFailureCategory
A simple categorization of the failure that was encountered while attempting the transaction. Note: This is meant to be an informative abstraction beyond the raw response codes provided by payment gateways. Possible values may include: GATEWAY_CREDENTIALS_ERROR, INVALID_PAYMENT_METHOD, PROCESSING_FAILURE, GATEWAY_ERROR, or NETWORK_ERROR. -
getGatewayErrorCount
public int getGatewayErrorCount()The number of times a gateway errors occurred while processing this account. -
isEligibleForGatewayErrorRetries
public boolean isEligibleForGatewayErrorRetries()Declares whether this request is eligible to retry executing the transaction in the case of a gateway error. Note: This should be primarily determined based on the payment gateway being used. Some gateways support the ability to resend transaction requests without the risk of duplicate transactions, but that can NOT be said for all gateways. -
getTransactionAdditionalFields
Name/Value pairs of additional attributes. This is the place to pass through gateway-specific information -
isResultHandled
public boolean isResultHandled()Indicates that this account result has been handled by the payment result handler. -
getBillingEventPaymentIdToRefund
BillingEventPaymentId of the RefundEventDetail -
setPaymentAccount
The PaymentAccount associated to this request -
setPaymentProcessor
Code for the payment processor used for the transaction. Ex: CYBERSOURCE, PAYPAL -
setTransactionReferenceId
This unique value is used by the processor to rule out the duplicates -
setTransactionType
Transaction type of the transaction- See Also:
-
setDateProcessed
The date and time this transaction was sent to the processor -
setStatus
The status of this account processing request. -
setProcessingResult
The result of this payment processing request. -
setRawResponse
The raw response from the payment processor -
setFailureReason
Reason for the transaction failure -
setFailureType
Describes the severity of the failure.PaymentFailureTypeEnum.HARD_FAILUREdescribes a failure where the payment method can no longer be used (e.g. card stolen), whereasPaymentFailureTypeEnum.SOFT_FAILUREdescribes a failure where transactions with the payment method can be attempted in the future (e.g. insufficient funds) -
setFailureCategory
A simple categorization of the failure that was encountered while attempting the transaction. Note: This is meant to be an informative abstraction beyond the raw response codes provided by payment gateways. Possible values may include: GATEWAY_CREDENTIALS_ERROR, INVALID_PAYMENT_METHOD, PROCESSING_FAILURE, GATEWAY_ERROR, or NETWORK_ERROR. -
setGatewayErrorCount
public void setGatewayErrorCount(int gatewayErrorCount) The number of times a gateway errors occurred while processing this account. -
setEligibleForGatewayErrorRetries
public void setEligibleForGatewayErrorRetries(boolean eligibleForGatewayErrorRetries) Declares whether this request is eligible to retry executing the transaction in the case of a gateway error. Note: This should be primarily determined based on the payment gateway being used. Some gateways support the ability to resend transaction requests without the risk of duplicate transactions, but that can NOT be said for all gateways. -
setTransactionAdditionalFields
Name/Value pairs of additional attributes. This is the place to pass through gateway-specific information -
setResultHandled
public void setResultHandled(boolean resultHandled) Indicates that this account result has been handled by the payment result handler. -
setBillingEventPaymentIdToRefund
BillingEventPaymentId of the RefundEventDetail -
equals
-
canEqual
-
hashCode
public int hashCode() -
toString
-
getBillingEventPaymentIdToRefund()