com.ibm.commerce.fulfillment.commands
Class InventoryBaseCmdImpl
java.lang.Object
|
+--com.ibm.commerce.command.AbstractECCommand
|
+--com.ibm.commerce.command.TaskCommandImpl
|
+--com.ibm.commerce.fulfillment.commands.InventoryBaseCmdImpl
- All Implemented Interfaces:
- CheckInventoryCmd, ECCommand, ReverseUpdateInventoryCmd, TaskCommand, UpdateInventoryCmd
- Direct Known Subclasses:
- CheckInventoryCmdImpl, ResolveFulfillmentCenterCmdImpl, ReverseUpdateInventoryCmdImpl, UpdateInventoryCmdImpl, UpdateInventoryForOrderItemsCmdImpl
- public class InventoryBaseCmdImpl
- extends TaskCommandImpl
- implements CheckInventoryCmd, UpdateInventoryCmd, ReverseUpdateInventoryCmd
This is the base class for the CheckInventory, UpdateInventory and ReverseUpdateInventory.
Methods inherited from class com.ibm.commerce.command.AbstractECCommand |
accessControlCheck, checkIsAllowed, checkResourcePermission, execute, finalize, getAccCheck, getCommandContext, getCommandIfName, getCommandName, getDefaultProperties, getResources, getStoreId, getUser, getUserId, 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.ECCommand |
checkIsAllowed, checkResourcePermission, execute, getAccCheck, getCommandContext, getCommandIfName, getCommandName, getDefaultProperties, getResources, getStoreId, getUser, getUserId, setAccCheck, setCommandContext, setCommandIfName, setDefaultProperties |
CHECK_INVENTORY
public static final java.lang.String CHECK_INVENTORY
COPYRIGHT
public static final java.lang.String COPYRIGHT
ERR_CHECK_INV
public static final java.lang.String ERR_CHECK_INV
iAction
protected java.lang.String iAction
iCatEntryId
protected java.lang.Long iCatEntryId
iFulfillmentCenterId
protected java.lang.Integer iFulfillmentCenterId
iOrderItems
protected OrderItemAccessBean[] iOrderItems
iQuantity
protected java.lang.Double iQuantity
iQuantityMeasure
protected java.lang.String iQuantityMeasure
iShipModeId
protected java.lang.Integer iShipModeId
iStoreId
protected java.lang.Integer iStoreId
NO_CHECK
public static final int NO_CHECK
NO_RECOMMENDATION
public static final int NO_RECOMMENDATION
NO_UPDATE
public static final int NO_UPDATE
REVERSE_UPDATE_INVENTORY
public static final java.lang.String REVERSE_UPDATE_INVENTORY
UPDATE_INVENTORY
public static final java.lang.String UPDATE_INVENTORY
InventoryBaseCmdImpl
public InventoryBaseCmdImpl()
checkUpdateInventory
protected boolean checkUpdateInventory(InventoryAccessBean inventoryAB,
java.lang.Double askQuantity)
throws ECException
convertQuantity
protected java.lang.Double convertQuantity(java.lang.Double quantity,
java.lang.String quantityUnit,
java.lang.String newQuantityUnit)
throws ECException
convertQuantity
protected java.lang.Double convertQuantity(OrderItemAccessBean orderItemAB,
java.lang.String newQuantityUnit)
throws java.rmi.RemoteException,
javax.ejb.CreateException,
javax.naming.NamingException,
javax.ejb.FinderException,
ECException
findByCatalogEntryAndFulfillmentCenterAndStore
protected InventoryAccessBean findByCatalogEntryAndFulfillmentCenterAndStore(java.lang.Long catalogEntryId,
java.lang.Integer fulfillmentCenterId,
java.lang.Integer storeId)
throws java.rmi.RemoteException,
javax.ejb.CreateException,
javax.naming.NamingException,
javax.ejb.FinderException,
ECException
flagIsSet
protected boolean flagIsSet(int flag)
getCatEntryId
protected java.lang.Long getCatEntryId()
getFulfillmentCenterId
protected java.lang.Integer getFulfillmentCenterId()
getOrderItem
protected OrderItemAccessBean[] getOrderItem()
getQuantity
protected java.lang.Double getQuantity()
getQuantityMeasure
protected java.lang.String getQuantityMeasure()
isReadyToCallExecute
public boolean isReadyToCallExecute()
- Description copied from class:
AbstractECCommand
- isReadyToCallExecute method is called by the Targetable Command frame work
This is where client side parameter checking is performed before the execution of the command.
The default implementation is to return true.
- Overrides:
isReadyToCallExecute
in class AbstractECCommand
- Following copied from class:
com.ibm.commerce.command.AbstractECCommand
- Returns:
- boolean - true if we can execute the command
false if we canot execute the command
performExecute
public void performExecute()
throws ECException
- Description copied from interface:
ECCommand
- Contains the actual business logic of the command
It should be implemented by all the command writer.
- Specified by:
performExecute
in interface ECCommand
- 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.
reset
public void reset()
- Description copied from class:
AbstractECCommand
- This method is called after a command has been executed to reset its states variables.
After the call to reset, we should be able to execute the command again.
- Overrides:
reset
in class AbstractECCommand
setCatEntryId
public void setCatEntryId(java.lang.Long aCatEntryId)
- Set a Catalog Entry Id.
- Specified by:
setCatEntryId
in interface CheckInventoryCmd
setFulfillmentCenterId
public void setFulfillmentCenterId(java.lang.Integer aFulfillmentCenterId)
- Set a fulfillment center Id.
- Specified by:
setFulfillmentCenterId
in interface CheckInventoryCmd
setOrderItem
public void setOrderItem(OrderItemAccessBean anOrderItem)
- Set an OrderItem.
- Specified by:
setOrderItem
in interface CheckInventoryCmd
setOrderItem
public void setOrderItem(OrderItemAccessBean[] orderItems)
- Set a list of OrderItems.
- Specified by:
setOrderItem
in interface CheckInventoryCmd
setOrderItem
public void setOrderItem(java.util.Vector anOrderItemList)
- Set a list of OrderItems.
- Specified by:
setOrderItem
in interface CheckInventoryCmd
setQuantity
public void setQuantity(java.lang.Double aQuantity)
- Set a quantity.
- Specified by:
setQuantity
in interface CheckInventoryCmd
setQuantityMeasure
public void setQuantityMeasure(java.lang.String quantityMeasure)
- Set a quantity measure.
- Specified by:
setQuantityMeasure
in interface CheckInventoryCmd
setStoreId
public void setStoreId(java.lang.Integer aStoreId)
- Set a store id.
- Specified by:
setStoreId
in interface CheckInventoryCmd
validateParameters
public void validateParameters()
throws ECException
- Description copied from interface:
ECCommand
- Performs server side parameter checking. This method replaces the checkParameters() method in a previous
version of the code.
- Specified by:
validateParameters
in interface ECCommand
- Overrides:
validateParameters
in class AbstractECCommand
- Following copied from interface:
com.ibm.commerce.command.ECCommand
- Throws:
ECException.
-