Class DefaultPaymentVersionValidationService
java.lang.Object
com.broadleafcommerce.paymenttransaction.service.validation.DefaultPaymentVersionValidationService
- All Implemented Interfaces:
PaymentVersionValidationService
public class DefaultPaymentVersionValidationService
extends Object
implements PaymentVersionValidationService
The default implementation of
PaymentVersionValidationService.- Author:
- Chris Kittrell (ckittrell)
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidvalidateVersionForArchival(Payment payment, Integer versionToTest) Determines if the providedversionToTestis valid for an archival of thePayment.voidvalidateVersionForUpdate(Payment payment, Integer versionToTest) Determines if the providedversionToTestis valid for an update of thePayment.booleanversionIsStale(Payment payment, Integer versionToTest) Determines if the providedversionToTestis valid for thePayment.
-
Constructor Details
-
DefaultPaymentVersionValidationService
public DefaultPaymentVersionValidationService()
-
-
Method Details
-
versionIsStale
Description copied from interface:PaymentVersionValidationServiceDetermines if the providedversionToTestis valid for thePayment.- Specified by:
versionIsStalein interfacePaymentVersionValidationService- Parameters:
payment- ThePaymentwhose version is being validated.versionToTest- The version provided by the request, which may or may not be out of date.- Returns:
- Whether the provided
versionToTestis valid for thePayment.
-
validateVersionForUpdate
Description copied from interface:PaymentVersionValidationServiceDetermines if the providedversionToTestis valid for an update of thePayment.- Specified by:
validateVersionForUpdatein interfacePaymentVersionValidationService- Parameters:
payment- ThePaymentwhose version is being validated.versionToTest- The version provided by the request, which may or may not be out of date.
-
validateVersionForArchival
Description copied from interface:PaymentVersionValidationServiceDetermines if the providedversionToTestis valid for an archival of thePayment.- Specified by:
validateVersionForArchivalin interfacePaymentVersionValidationService- Parameters:
payment- ThePaymentwhose version is being validated.versionToTest- The version provided by the request, which may or may not be out of date.
-