com.ibm.commerce.tools.optools.returns.commands
Class CSRDisplayRefundByOriginalPaymentCmdImpl

java.lang.Object
  |
  +--com.ibm.commerce.command.AbstractECCommand
        |
        +--com.ibm.commerce.command.TaskCommandImpl
              |
              +--com.ibm.commerce.command.BusinessPolicyCommandImpl
                    |
                    +--com.ibm.commerce.tools.optools.returns.commands.CSRDisplayRefundPaymentInfoCmdImpl
                          |
                          +--com.ibm.commerce.tools.optools.returns.commands.CSRDisplayRefundByOriginalPaymentCmdImpl
All Implemented Interfaces:
BusinessPolicyCommand, CSRDisplayRefundPaymentInfoCmd, ECCommand, TaskCommand

public class CSRDisplayRefundByOriginalPaymentCmdImpl
extends CSRDisplayRefundPaymentInfoCmdImpl

Brief Description:


  Policy command that retrives the credit information for a return.
  This command gets executed for rma's whose refund policy type is
  set to 'use original order' meaning the credit will go to the account
  used to originally order the merchandise.

Input parameters:

  RMAAccessBean - set the RMAAcessBean using the setRMA(...) method
 
Output parameters:

  This command populates a data structure with the credit account information.
  To retrive the data structure call the getCreditAccountInformation() method.
   
  This method returns a Vector of Hashtables that contain Hashtables. 
  A sample usage of the output is as follows:
 

 		Vector creditInfo  = getCreditAccountInformation()

		if ( creditInfo != null && creditInfo.size() != 0 )
		{
		   for (int i = 0; i < creditInfo.size(); i++ )
		   {
	   
		      Hashtable ht1 = (Hashtable) creditInfo.elementAt(i);
		      Enumeration enum = ht1.elements();
		      Hashtable ht2 = (Hashtable) enum.nextElement(); // only 1 element in this hashtable
		      String labelKey = (String) ht2.get("LABEL_KEY"); // gets the label key from the ReturnNLS.properties file
		      String value = (String) ht2.get("VALUE");		// gets the value
		   }
		}   
   


Fields inherited from class com.ibm.commerce.tools.optools.returns.commands.CSRDisplayRefundPaymentInfoCmdImpl
creditAccountInformation, iRMA
 
Fields inherited from class com.ibm.commerce.command.BusinessPolicyCommandImpl
policyId, requestProperties
 
Fields inherited from class com.ibm.commerce.command.AbstractECCommand
commandContext
 
Fields inherited from interface com.ibm.commerce.tools.optools.returns.commands.CSRDisplayRefundPaymentInfoCmd
COPYRIGHT, defaultCommandClassName, NAME
 
Constructor Summary
CSRDisplayRefundByOriginalPaymentCmdImpl()
           
 
Method Summary
 void performExecute()
          Executes the policy command.
 void populateCreditAccountInformation()
          Populate the refund credit account information
 void validateParameters()
          Validate input parameters.
 
Methods inherited from class com.ibm.commerce.tools.optools.returns.commands.CSRDisplayRefundPaymentInfoCmdImpl
addInfoToVector, getCreditAccountInformation, getRMA, setRMA
 
Methods inherited from class com.ibm.commerce.command.BusinessPolicyCommandImpl
getPolicyId, getRequestProperties, setPolicyId, setRequestProperties
 
Methods inherited from class com.ibm.commerce.command.AbstractECCommand
accessControlCheck, checkIsAllowed, checkResourcePermission, execute, finalize, getAccCheck, getCommandContext, getCommandIfName, getCommandName, getDefaultProperties, getResources, getStoreId, getUser, getUserId, isReadyToCallExecute, reset, setAccCheck, setCommandContext, setCommandIfName, setDefaultProperties
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.ibm.commerce.command.BusinessPolicyCommand
getPolicyId, getRequestProperties, setPolicyId, setRequestProperties
 
Methods inherited from interface com.ibm.commerce.command.ECCommand
checkIsAllowed, checkResourcePermission, execute, getAccCheck, getCommandContext, getCommandIfName, getCommandName, getDefaultProperties, getResources, getStoreId, getUser, getUserId, setAccCheck, setCommandContext, setCommandIfName, setDefaultProperties
 

Constructor Detail

CSRDisplayRefundByOriginalPaymentCmdImpl

public CSRDisplayRefundByOriginalPaymentCmdImpl()
Method Detail

performExecute

public void performExecute()
                    throws ECException
Executes the policy command.
Overrides:
performExecute in class AbstractECCommand
Following copied from interface: com.ibm.commerce.command.ECCommand
Throws:
com.ibm.commerce.command.CommandException - The superclass for all ECExceptions.

populateCreditAccountInformation

public void populateCreditAccountInformation()
                                      throws ECException
Populate the refund credit account information

validateParameters

public void validateParameters()
                        throws ECException
Validate input parameters.
Overrides:
validateParameters in class AbstractECCommand
Following copied from interface: com.ibm.commerce.command.ECCommand
Throws:
ECException. -