com.ibm.commerce.payment.commands

Class DoRefundCmdImpl

  • All Implemented Interfaces:
    com.ibm.commerce.command.CacheableECCommand, ECCommand, ECTargetableCommand, TaskCommand, DoRefundCmd, 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

    Deprecated. 

    public class DoRefundCmdImpl
    extends TaskCommandImpl
    implements DoRefundCmd
    Default DoRefund task command implementation.

    This command handles the refund for the given order and Return Merchandise Authorization (RMA).

    Parameters:

    Parameter Name Type Descriptions
    abRMA RMAAccessBean The RMAAccessBean for the Return Merchandise Authorization (RMA) record
    abOrder OrderAccessBean The OrderAccessBean of the order associated with the RMA
    bdRefundAmount BigDecimal The amount of the refund in the currency specified in the RMA
    nReturnPolicyId Long The ID of the Return Business Policy

    Behavior:

    • Calls the UpdateTARefund Task command to update the Refund records of the Trading Agreement.
    • Calls the CreditAccount command to debit the account through an external Accounting System.
    • Finally, calls the RefundPaymentPolicy specified by the nReturnPolicyId. (The RefundPaymentPolicyCmd Command will in turn call the DoRefundPolicy Command with the appropriate Payment Policy ID.)

    Error View Name:

    • DoRefundErrorView

    ErrorCodes:

    • (Include error codes from the other subordinate commands)

    This command uses the following AccessBeans:

    This command calls the following TaskCommands:

    This command calls the following BusinessPolicyCommands:

    See Also:
    Serialized Form
    • Constructor Detail

      • DoRefundCmdImpl

        public DoRefundCmdImpl()
        Deprecated. 
    • Method Detail

      • isReadyToCallExecute

        public boolean isReadyToCallExecute()
        Deprecated. 
        This method is called by the Command Framework to check if all basic mandatory parameters have been set for this command. This is done before the Framework calls the performExecute method of the command.
        Specified by:
        isReadyToCallExecute in interface com.ibm.websphere.command.Command
        Overrides:
        isReadyToCallExecute in class AbstractECTargetableCommand
        Returns:
        true if we can execute the command; false otherwise.
      • reset

        public void reset()
        Deprecated. 
        Resets the instance variables of the command. The reset() method will reset all instance variables. If the command includes any output values that are accessible via getters, then make sure those values are no longer needed before calling this method to reset the instance variables of the command.

        This is useful if the command instance is to be called multiple times with different command parameters.

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

        public void setOrder(OrderAccessBean ab)
        Deprecated. 
        Sets the order property of the command.
        Specified by:
        setOrder in interface DoRefundCmd
        Parameters:
        ab - the OrderAccessBean representing the Order associated with the Return Merchandise Authorization.
      • setRefundAmount

        public void setRefundAmount(java.math.BigDecimal refundAmount)
        Deprecated. 
        Sets the refundAmount property of the command.
        Specified by:
        setRefundAmount in interface DoRefundCmd
        Parameters:
        refundAmount - the amount to be refunded in the currency specified in in the Return Merchandise Authorization
      • setReturnPolicyId

        public void setReturnPolicyId(java.lang.Long nReturnPolicyId)
        Deprecated. 
        Sets the returnPolicyId property of the command.
        Specified by:
        setReturnPolicyId in interface DoRefundCmd
        Parameters:
        nReturnPolicyId - the Return Policy ID for this refund
      • setRMA

        public void setRMA(RMAAccessBean ab)
        Deprecated. 
        Sets the Return Merchandise Authorization record that authorizes the return of the merchandise.
        Specified by:
        setRMA in interface DoRefundCmd
        Parameters:
        ab - the RMAAccessBean for the Return Merchandise Authorization record