com.ibm.commerce.order.calculation
Interface CalculationCodeApplyCmd

All Superinterfaces:
BusinessPolicyCommand, CalculationCmd, TaskCommand
All Known Subinterfaces:
DiscountCalculationCodeApplyCmd, SalesTaxCalculationCodeApplyCmd, ShippingCalculationCodeApplyCmd, ShippingTaxCalculationCodeApplyCmd
All Known Implementing Classes:
DiscountCalculationCodeApplyCmdImpl, SalesTaxCalculationCodeApplyCmdImpl, ShippingCalculationCodeApplyCmdImpl, ShippingTaxCalculationCodeApplyCmdImpl, TaxCalculationCodeApplyCmdImpl

public interface CalculationCodeApplyCmd
extends CalculationCmd

Given a calculation code, a list of items and a corresponding list of values, commands that extend this interface will apply each value to its corresponding item.

For sales/shipping tax only, the caller can specify a list of values for each sales/shipping tax category defined in the current store.

This is the base interface that commands registered as calculation methods of type "CalculationCodeApply" must extend. These commands include:


Field Summary
static java.lang.String COPYRIGHT
          The IBM copyright notice field.
static java.lang.String defaultCommandClassName
          Deprecated.  
static java.lang.String NAME
          The name of this interface.
 
Method Summary
 void setCode(CalculationCodeAccessBean aabCode)
          Sets the calculation code.
 void setItems( Item[] aItems)
          Sets the items.
 void setValues(java.math.BigDecimal[] adValues)
          Sets the values to apply.
 void setValues(java.lang.Integer anTaxCategoryId, java.math.BigDecimal[] adValues)
          Sets values to apply for a tax category.
 
Methods inherited from interface com.ibm.commerce.order.calculation. CalculationCmd
getCurrency, getCustomProperties, getCustomProperty, getTimestamp, getUsageId, setCurrency, setCustomProperties, setCustomProperty, setTimestamp, setUsageId
 
Methods inherited from interface com.ibm.commerce.command. BusinessPolicyCommand
getPolicyId, getRequestProperties, setPolicyId, setRequestProperties
 

Field Detail
public static final java.lang.String COPYRIGHT
The IBM copyright notice field.
See Also:
Constant Field Values

NAME

public static final java.lang.String NAME
The name of this interface.
See Also:
Constant Field Values

defaultCommandClassName

public static final java.lang.String defaultCommandClassName
Deprecated.  
See Also:
Constant Field Values
Method Detail

setCode

public void setCode(CalculationCodeAccessBean aabCode)
Sets the calculation code.
Parameters:
aabCode - the calculation code.

setItems

public void setItems(Item[] aItems)
Sets the items.
Parameters:
aItems - the items.

setValues

public void setValues(java.math.BigDecimal[] adValues)
Sets the values to apply.
Parameters:
adValues - the values.

setValues

public void setValues(java.lang.Integer anTaxCategoryId,
                      java.math.BigDecimal[] adValues)
Sets values to apply for a tax category. For sales/shipping tax only.
Parameters:
anTaxCategoryId - the tax category ID.
adValues - the values.