Interface PaymentPriorityStrategy
-
- All Known Implementing Classes:
DefaultPaymentPriorityStrategy
public interface PaymentPriorityStrategyA helper component that has understanding of whichPaymentSummariestake precedence and should be applied first in various operations such as payment capture, reverse authorize, and refund.- Author:
- Samarth Dhruva (samarthd), Sunny Yu
-
-
Method Summary
All Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method Description List<PaymentSummary>sortByPaymentGatewayPriorityForCapture(List<PaymentSummary> payments, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Given a list ofPaymentSummaries, sorts them in order of which should be executed first.List<PaymentSummary>sortByPaymentGatewayPriorityForRefund(List<PaymentSummary> payments, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Given a list ofPaymentSummaries, sorts them in order of which should be executed first.List<PaymentSummary>sortByRefundPriority(List<PaymentSummary> payments)Deprecated.since 1.7.2, in favor ofsortByPaymentGatewayPriorityForRefund(List, ContextInfo)
-
-
-
Method Detail
-
sortByPaymentGatewayPriorityForCapture
List<PaymentSummary> sortByPaymentGatewayPriorityForCapture(List<PaymentSummary> payments, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Given a list ofPaymentSummaries, sorts them in order of which should be executed first.- Parameters:
payments- the payments to sortcontextInfo- context information surrounding sandboxing and multitenant state- Returns:
- a new list representing the sorted result. Will be empty if
paymentsis null or empty.
-
sortByPaymentGatewayPriorityForRefund
List<PaymentSummary> sortByPaymentGatewayPriorityForRefund(List<PaymentSummary> payments, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Given a list ofPaymentSummaries, sorts them in order of which should be executed first.- Parameters:
payments- the payments to sortcontextInfo- context information surrounding sandboxing and multitenant state- Returns:
- a new list representing the sorted result. Will be empty if
paymentsis null or empty.
-
sortByRefundPriority
@Deprecated List<PaymentSummary> sortByRefundPriority(@Nullable List<PaymentSummary> payments)
Deprecated.since 1.7.2, in favor ofsortByPaymentGatewayPriorityForRefund(List, ContextInfo)Given a list ofPaymentSummaries, sorts them in order of which should be refunded first.- Parameters:
payments- the payments to sort- Returns:
- a new list representing the sorted result. Will be empty if
paymentsis null or empty.
-
-