java.lang.ObjectCacheableCommandImpl
com.ibm.commerce.command.AbstractECTargetableCommand
com.ibm.commerce.command.TaskCommandImpl
com.ibm.commerce.command.BusinessPolicyCommandImpl
com.ibm.commerce.returns.commands.CalculateReturnItemAdjustmentPolicyCmdImpl
Calculate the adjustment for a return mechandise authorization (RMA) item. This is an abstract implementation which supplies some common infrastructure for concrete implementations.
Behaviour
Field Summary |
Fields inherited from class com.ibm.commerce.command.BusinessPolicyCommandImpl |
policyId, requestProperties |
Fields inherited from class com.ibm.commerce.command.AbstractECTargetableCommand |
commandContext |
Fields inherited from interface com.ibm.commerce.returns.commands.CalculateReturnItemAdjustmentPolicyCmd |
COPYRIGHT, defaultCommandClassName, NAME |
Fields inherited from interface com.ibm.commerce.command.ECCommand |
defaultCommandClassName |
Constructor Summary | |
CalculateReturnItemAdjustmentPolicyCmdImpl() ReturnItemCreditCalculateCmdImpl constructor comment. |
Method Summary | |
protected abstract java.math.BigDecimal | calcAdjustment() Calculate the RMA item adjustment (charge). |
protected java.sql.Timestamp | calcTimestampShipped() Calculate the timestamp when the item was shipped. |
protected void | createCharge(java.lang.String aChargeType, java.math.BigDecimal anAmount) Create a charge against the rma item. |
protected int | findBestDays(int aDaysSinceShipped, int[] theDays) Find the smallest days value that is >= number of days since the item was shipped. |
java.math.BigDecimal | getAdjustment() Get the automatically calculated adjustment for the returned/refunded item. |
protected int | getDaysSince(java.sql.Timestamp aTimestamp) Get the number of days since a particluar timestamp value. |
protected OrderItemAccessBean | getOrderItemAB() Get the order item access bean. |
protected RMAItemAccessBean | getRMAItemAB() Get the RMA item access bean. |
protected java.math.BigDecimal | getTotalToAdjust() Get the amount to be used to calculate the adjustment. |
void | performExecute() Execute the command. |
protected void | removeExistingCharges() Remove existing charges. |
void | reset() reset the command. |
void | setOrderItemAB(OrderItemAccessBean anOrderItemAB) (Optional) Set the orderItem being returned/refunded. |
void | setRequestProperties(TypedProperty requestProperties) Set the request properties for the policy. |
void | setRMAItemAB(RMAItemAccessBean anRMAItemAB) Set the RMA Item access bean which will have its adjustment updated. |
void | validateParameters() Check mandatory parameters. |
Methods inherited from class com.ibm.commerce.command.BusinessPolicyCommandImpl |
getPolicyId, getRequestProperties, setPolicyId |
Methods inherited from class com.ibm.commerce.command.AbstractECTargetableCommand |
accessControlCheck, checkIsAllowed, checkParameters, checkResourcePermission, createCommandExecutionEvent, execute, finalize, getAccCheck, getCommandContext, getCommandIfName, getCommandName, getCommandStoreId, getDefaultProperties, getResources, getStoreId, getUser, getUserId, isReadyToCallExecute, setAccCheck, setCommandContext, setCommandIfName, setCommandStoreId, 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 |
Constructor Detail |
public CalculateReturnItemAdjustmentPolicyCmdImpl()
Method Detail |
protected abstract java.math.BigDecimal calcAdjustment() throws ECException
protected java.sql.Timestamp calcTimestampShipped() throws FinderException, java.rmi.RemoteException, javax.naming.NamingException, CreateException, ECException
protected void createCharge(java.lang.String aChargeType, java.math.BigDecimal anAmount) throws ECSystemException
protected int findBestDays(int aDaysSinceShipped, int[] theDays)
public java.math.BigDecimal getAdjustment()
protected int getDaysSince(java.sql.Timestamp aTimestamp)
protected OrderItemAccessBean getOrderItemAB()
protected RMAItemAccessBean getRMAItemAB()
protected java.math.BigDecimal getTotalToAdjust() throws ECSystemException
public void performExecute() throws ECException
protected void removeExistingCharges() throws ECSystemException
public void reset()
public void setOrderItemAB(OrderItemAccessBean anOrderItemAB)
public void setRequestProperties(TypedProperty requestProperties)
public void setRMAItemAB(RMAItemAccessBean anRMAItemAB)
public void validateParameters() throws ECException
(C) Copyright IBM Corporation 1996, 2005. All Rights Reserved.