ReferencedRefundNotification Class
Namespace
Usage
The constructor of this class takes no arguments. For example:
CommercePayments.ReferencedRefundNotification rrn = new CommercePayments.ReferencedRefundNotification();Example
commercepayments.NotificationStatus notificationStatus = null;
if (success) {
notificationStatus = commercepayments.NotificationStatus.Success;
} else {
notificationStatus = commercepayments.NotificationStatus.Failed;
}
commercepayments.BaseNotification notification = null;
if ('CAPTURE'.equals(eventCode)) {
notification = new commercepayments.CaptureNotification();
} else if ('REFUND'.equals(eventCode)) {
notification = new commercepayments.ReferencedRefundNotification();
}
ReferencedRefundNotification Methods
The following are methods for ReferencedRefundNotification.
setAmount(amount)
Signature
global void setAmount(Double amount)
Parameters
- amount
- Type: Double
- The amount to be debited or captured.
Return Value
Type: void
setGatewayDate(gatewayDate)
Signature
global void setGatewayDate(Datetime gatewayDate)
Parameters
- gatewayDate
- Type: Datetime
- The date that communication happened with the gateway.
Return Value
Type: void
setGatewayMessage(gatewayMessage)
Signature
global void setGatewayMessage(String gatewayMessage)
Parameters
- gatewayMessage
- Type: String
Return Value
Type: void
setGatewayReferenceDetails(gatewayReferenceDetails)
Signature
global void setGatewayReferenceDetails(String gatewayReferenceDetails)
Parameters
- gatewayReferenceDetails
- Type: String
- Provides information about the gateway communication.
Return Value
Type: void
setGatewayReferenceNumber(gatewayReferenceNumber)
Signature
global void setGatewayReferenceNumber(String gatewayReferenceNumber)
Parameters
- gatewayReferenceNumber
- Type: String
- Unique transaction ID created by the payment gateway.
Return Value
Type: void
setGatewayResultCode(gatewayResultCode)
Signature
global void setGatewayResultCode(String gatewayResultCode)
Parameters
- gatewayResultCode
- Type: String
- The gateway result code. You must map this to a Salesforce-specific result code.
Return Value
Type: void
setGatewayResultCodeDescription(gatewayResultCodeDescription)
Signature
global void setGatewayResultCodeDescription(String gatewayResultCodeDescription)
Parameters
- gatewayResultCodeDescription
- Type: String
- Description of the gateway result code. Provides additional context about the result code .
Return Value
Type: void
setSalesforceResultCodeInfo(salesforceResultCodeInfo)
Signature
global void setSalesforceResultCodeInfo(commercepayments.SalesforceResultCodeInfo salesforceResultCodeInfo)
Parameters
- salesforceResultCodeInfo
- Type: SalesforceResultCodeInfo
- Description of the Salesforce result code value.
Return Value
Type: void
setStatus(status)
Signature
global void setStatus(commercepayments.NotificationStatus status)
Parameters
- status
- Type: NotificationStatus
- Indicates whether the payments platform successfully received the notification from the payment gateway.
Return Value
Type: void