Class CalculateReturnItemCreditCmdImpl

  • All Implemented Interfaces:, ECCommand, ECTargetableCommand, TaskCommand, CalculateReturnItemCreditCmd,,,,,,

    public class CalculateReturnItemCreditCmdImpl
    extends TaskCommandImpl
    implements CalculateReturnItemCreditCmd
    Default implementation of the CalculateReturnItemCreditCmd interface. Calculate the automatic credit for a return merchandise authorization (RMA) item associated with a complete order item.


    • Call the task command CalculateReturnItemProductCreditCmd and set the CREDITAMOUNT field of the RMA item to its result.
    • Call the task command CalculateReturnItemAdjustmentCreditCmd and set the ADJUSTMENTCREDIT field of the RMA item to its result.
    • Call the business policy command CalculateReturnItemAdjustmentPolicyCmd to calculate the charges.

    Utilizes these access beans

    See Also:
    Serialized Form
    • Constructor Detail

      • CalculateReturnItemCreditCmdImpl

        public CalculateReturnItemCreditCmdImpl()
        CalculateReturnItemCreditCmdImpl constructor.
    • Method Detail

      • reset

        public void reset()
        Reset the command.
        Specified by:
        reset in interface
        reset in class AbstractECTargetableCommand
      • setQuantity

        public void setQuantity(java.lang.Double aQuantity)
        Set the quantity to be credited.
        Specified by:
        setQuantity in interface CalculateReturnItemCreditCmd
        aQuantity - The quantity to be credited.
      • validateParameters

        public void validateParameters()
                                throws ECException
        Check mandatory parameters. Checks the following parameters:


        • StoreAccessBean
          • StoreAccessBean passed in the command context
        • OrderItemAB
          • OrderitemAccesBean of the Order item
        • RMAItemAB
          • RMAItemAccessBean of the RMA item
        • RMAAB
          • RMAAccessBean of the RMA
        • Quantity
          • quantity of items to return

        Specified by:
        validateParameters in interface ECCommand
        validateParameters in class AbstractECTargetableCommand
        ECApplicationException - If there is no StoreAccessBean or there is no RMAItemAccessBean or there is no OrderItemAccessBean or there is no RMAccessBean or a quantity has not be specified , throws with ECMessage._ERR_BAD_MISSING_CMD_PARAMETER