com.ibm.commerce.edp.commands

Class EvaluatePaymentRulesCmdImpl

  • All Implemented Interfaces:
    com.ibm.commerce.command.CacheableECCommand, ECCommand, ECTargetableCommand, TaskCommand, EvaluatePaymentRulesCmd, 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 EvaluatePaymentRulesCmdImpl
    extends TaskCommandImpl
    implements EvaluatePaymentRulesCmd
    This is the default implementation of the EvaluatePaymentRulesCmd task command.

    Behaviour:

    • It calls RuleReader to read the payment rules and decide what actions should be executed.

    Input parameters:

    rulePhase An int that indicates the phase of the rule.
    commandContext The command context.
    storeId An Integer that specifies the store id.
    orderChannel A String that specifies the order channel.
    edpOrderId A Long that specifies the EDP order id.
    amountToProcess A BigDecimal that specifies the amount to be processed.
    hashOfActionList A HashMap that represents the list of current actions.
    phase An int that indicates the current phase.
    edpReleaseIds A List that represents the ids of the EDP releases.

    Output parameters:

    None.

    Task commands called:

    See Also:
    Serialized Form
    • Field Detail

      • COPYRIGHT

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

        public static final java.lang.String CLASS_NAME
        The name of the class.
        See Also:
        Constant Field Values
    • Constructor Detail

      • EvaluatePaymentRulesCmdImpl

        public EvaluatePaymentRulesCmdImpl()
    • Method Detail

      • setEDPPaymentInstructionId

        public void setEDPPaymentInstructionId(java.lang.Long localPiId)
        This method sets the payment instruction id in payment rule.
        Specified by:
        setEDPPaymentInstructionId in interface EvaluatePaymentRulesCmd
        Parameters:
        localPiId - A Long that specifies the current payment instruction id.
      • setEDPOrderId

        public void setEDPOrderId(java.lang.Long edpOrder)
        This method sets the EDP order id.
        Specified by:
        setEDPOrderId in interface EvaluatePaymentRulesCmd
        Parameters:
        edpOrder - A Long that specifies the current EDP order id.
      • setAmountToProcess

        public void setAmountToProcess(java.math.BigDecimal amtToProcess)
        This method sets the amount to be processed.
        Specified by:
        setAmountToProcess in interface EvaluatePaymentRulesCmd
        Parameters:
        amtToProcess - A BigDecimal that specifies the current amount to process.
      • setEDPReleaseId

        public void setEDPReleaseId(java.util.List edpReleaseIdList)
        This method sets the release id in payment rule.
        Specified by:
        setEDPReleaseId in interface EvaluatePaymentRulesCmd
        Parameters:
        edpReleaseIdList - A List that represents the ids of the EDP releases.
      • setPhase

        public void setPhase(int localPhase)
        This method sets the current phase.
        Specified by:
        setPhase in interface EvaluatePaymentRulesCmd
        Parameters:
        localPhase - An int that indicates the current phase.
      • getActionDatas

        public java.util.HashMap getActionDatas()
        This method gets the current action datas.
        Specified by:
        getActionDatas in interface EvaluatePaymentRulesCmd
        Returns:
        A HashMap that represents the list of current action datas.
      • setAtomicPaymentId

        public void setAtomicPaymentId(java.lang.Long atmPaymentId)
        This method sets the atomic payment id.
        Specified by:
        setAtomicPaymentId in interface EvaluatePaymentRulesCmd
        Parameters:
        atmPaymentId - A Long that specifies the atomic payment id.
      • setRuleType

        public void setRuleType(java.lang.String string)
        This method sets the rule type.
        Specified by:
        setRuleType in interface EvaluatePaymentRulesCmd
        Parameters:
        string - A String that specifies the rule type.
      • getRuleType

        public java.lang.String getRuleType()
        This method returns the current rule type.
        Returns:
        A String that specifies the rule type.
      • getRulePhase

        public int getRulePhase()
        This method returns the current rule phase.
        Returns:
        An int that indicates the current rule phase.
      • setRulePhase

        public void setRulePhase(int i)
        This method sets the current rule phase.
        Specified by:
        setRulePhase in interface EvaluatePaymentRulesCmd
        Parameters:
        i - An int that indicates the current rule phase.
      • getHashOfActionList

        public java.util.HashMap getHashOfActionList()
        This method returns the HashMap that stores the current action list.
        Specified by:
        getHashOfActionList in interface EvaluatePaymentRulesCmd
        Returns:
        A HashMap that represents the list of current actions.
      • getListOfActionList

        public java.util.List getListOfActionList()
        This method returns the list of current action list.
        Specified by:
        getListOfActionList in interface EvaluatePaymentRulesCmd
        Returns:
        A List that represents the list of current actions.
      • setHashOfActionList

        public void setHashOfActionList(java.util.HashMap map)
        This method sets the HashMap that stores the current action list.
        Specified by:
        setHashOfActionList in interface EvaluatePaymentRulesCmd
        Parameters:
        map - A HashMap that represents the list of current actions.
      • setListOfActionList

        public void setListOfActionList(java.util.List localListOfActionList)
        This method sets the list of current action list.
        Specified by:
        setListOfActionList in interface EvaluatePaymentRulesCmd
        Parameters:
        localListOfActionList - A List that represents the list of current actions.
      • getException

        public java.lang.Throwable getException()
        This method returns the thrown exception.
        Specified by:
        getException in interface EvaluatePaymentRulesCmd
        Returns:
        A Throwable that represents the exception thrown.
      • setException

        public void setException(java.lang.Throwable object)
        This method sets the current thrown exception.
        Parameters:
        object - A Throwable that represents the current thrown exception.
      • getOrderChannel

        public java.lang.String getOrderChannel()
        This method returns the current order channel.
        Returns:
        A String that specifies the current order channel.
      • getPaymentGroupId

        public java.lang.String getPaymentGroupId()
        This method returns the current payment configuration group id.
        Returns:
        A String that specifies the id of payment group.
      • setOrderChannel

        public void setOrderChannel(java.lang.String string)
        This method sets the current order channel.
        Specified by:
        setOrderChannel in interface EvaluatePaymentRulesCmd
        Parameters:
        string - A String that specifies the current order channel.
      • setPaymentGroupId

        public void setPaymentGroupId(java.lang.String string)
        This method sets the current payment configuration group id.
        Parameters:
        string - A String that specifies the payment configuration group id.
      • setStoreId

        public void setStoreId(java.lang.Integer integer)
        This method sets the current store id.
        Specified by:
        setStoreId in interface EvaluatePaymentRulesCmd
        Parameters:
        integer - An Integer that specifies the id of the current store.
      • reset

        public void reset()

        This method resets the command fields.

        After this method is invoked, and proper attributes are set, the command can be executed again.

        Specified by:
        reset in interface com.ibm.websphere.command.Command
        Overrides:
        reset in class AbstractECTargetableCommand