com.ibm.commerce.payment.commands

Class ServiceProviderCheckPaymentPolicyDisplayCmdImpl

  • All Implemented Interfaces:
    com.ibm.commerce.command.CacheableECCommand, ECCommand, ECTargetableCommand, TaskCommand, CheckPaymentPolicyDisplayCmd, com.ibm.websphere.cache.Sizeable, com.ibm.websphere.command.CacheableCommand, com.ibm.websphere.command.Command, com.ibm.websphere.command.CommandCaller, com.ibm.websphere.command.TargetableCommand, java.io.Serializable


    public class ServiceProviderCheckPaymentPolicyDisplayCmdImpl
    extends CheckPaymentPolicyDisplayCmdImpl
    implements CheckPaymentPolicyDisplayCmd
    This is the default implementation of the ListPaymentPolicyCmd task command. It gets a list of PaymentPolicyInfo objects representing Payment Business Policies that the store supports.

    Input parameters:

    commandContext The command context.
    storeId The store id.

    Output parameters:

    paymentPolicyInfo[] an array of Payment Policy Info objects.
    See Also:
    Serialized Form
    • Field Detail

      • COPYRIGHT

        public static final java.lang.String COPYRIGHT
        IBM Copyright notice field.
        See Also:
        Constant Field Values
      • CLASSNAME

        public static final java.lang.String CLASSNAME
        The name of this command.
        See Also:
        Constant Field Values
    • Constructor Detail

      • ServiceProviderCheckPaymentPolicyDisplayCmdImpl

        public ServiceProviderCheckPaymentPolicyDisplayCmdImpl()
    • Method Detail

      • isDisplayAllowed

        public boolean isDisplayAllowed(BusinessPolicyAccessBean abPolicy)
        Check if the payment policy is allowed to display at the client. If it is not allowed, it will be removed from the displayed policies for the Store. The default behavior is to check time constraint and the properties of display=true/false. If checkDummyPayment=true in request property, set display=true for payment policy which display=false && spsDummy=false. If checkDummyPayment was not set or checkDummyPayment=false, set display=false for payment policy which display=true && spsDummy=true. This protected method can be overridden to implement other filter logic.
        Specified by:
        isDisplayAllowed in interface CheckPaymentPolicyDisplayCmd
        Overrides:
        isDisplayAllowed in class CheckPaymentPolicyDisplayCmdImpl
        Parameters:
        abPolicy - the payment policy to be checked
        Returns:
        true if the payment policy is allowed to display, otherwise return false
      • isDummyPaymentMethodAllowed

        public boolean isDummyPaymentMethodAllowed(java.lang.Long policyId)
        Check whether dummy payment method is allowed. Check checkDummyPayment value in request property. If checkDummyPayment=true, get payment policy's attribute 'spsDummy'. If spsDummy=true, return true that the dummy payment method is allowed.
        Specified by:
        isDummyPaymentMethodAllowed in interface CheckPaymentPolicyDisplayCmd
        Overrides:
        isDummyPaymentMethodAllowed in class CheckPaymentPolicyDisplayCmdImpl
        Parameters:
        policyId -
        Returns:
        boolean value whether dummy payment method is allowed