com.ibm.commerce.marketing.commands
Class AddPromotionCodeToOrderCOTaskCmdImpl
- java.lang.Object
-
- com.ibm.websphere.command.TargetableCommandImpl
-
- com.ibm.websphere.command.CacheableCommandImpl
-
- com.ibm.commerce.command.MeasuredCacheableCommandImpl
-
- com.ibm.commerce.command.AbstractECTargetableCommand
-
- com.ibm.commerce.command.TaskCommandImpl
-
- com.ibm.commerce.marketing.commands.AbstractAddPromotionCodeToOrderTaskCmdImpl
-
- com.ibm.commerce.marketing.commands.AddPromotionCodeToOrderCOTaskCmdImpl
-
- All Implemented Interfaces:
- com.ibm.commerce.command.CacheableECCommand, ECCommand, ECTargetableCommand, TaskCommand, AddPromotionCodeToOrderTaskCmd, 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
public class AddPromotionCodeToOrderCOTaskCmdImpl extends AbstractAddPromotionCodeToOrderTaskCmdImpl implements AddPromotionCodeToOrderTaskCmd
The class implementsAddPromotionCodeToOrderTaskCmd
to add a promotion code to an order and support unique promotion code implementation.- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from interface com.ibm.commerce.marketing.commands.AddPromotionCodeToOrderTaskCmd
defaultCommandClassName, NAME
-
-
Constructor Summary
Constructors Constructor and Description AddPromotionCodeToOrderCOTaskCmdImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description void
performExecute()
This method executes the business logic of this command implementation.void
reset()
This method is called after a command has been executed.void
setOrderId(java.lang.Long orderId)
This is the method to set order id.void
setPromotionCode(java.lang.String promotionCode)
This is the method to set promotion code.void
setPromotionCodeType(java.lang.Short promotionCodeType)
This method sets the implementation type that is used for promotion code.-
Methods inherited from class com.ibm.commerce.marketing.commands.AbstractAddPromotionCodeToOrderTaskCmdImpl
validateParameters
-
Methods inherited from class com.ibm.commerce.command.AbstractECTargetableCommand
accessControlCheck, checkIsAllowed, checkResourcePermission, createCommandExecutionEvent, execute, getAccCheck, getCommandContext, getCommandIfName, getCommandName, getCommandStoreId, getDefaultProperties, getExceptionInvokeParameters, getObjectSize, getPostInvokeParameters, getPreInvokeParameters, getResources, getStoreId, getUser, getUserId, isReadyToCallExecute, setAccCheck, setCommandContext, setCommandIfName, setCommandStoreId, setDefaultProperties
-
Methods inherited from class com.ibm.websphere.command.CacheableCommandImpl
executeFromCache, getCaller, getEntryInfo, getId, getSharingPolicy, postExecute, preExecute, setCaller, setObjectSize, unionDependencies, updateCache
-
Methods inherited from class com.ibm.websphere.command.TargetableCommandImpl
getCommandTarget, getCommandTargetName, getTargetPolicy, hasOutputProperties, setCommandTarget, setCommandTargetName, setHasOutputProperties, setOutputProperties, setTargetPolicy
-
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.ibm.websphere.command.CacheableCommand
executeFromCache, getCaller, getEntryInfo, getId, getSharingPolicy, postExecute, preExecute, setCaller, updateCache
-
Methods inherited from interface com.ibm.websphere.command.TargetableCommand
getCommandTarget, getCommandTargetName, hasOutputProperties, setCommandTarget, setCommandTargetName, setOutputProperties
-
Methods inherited from interface com.ibm.commerce.command.ECCommand
checkIsAllowed, checkResourcePermission, createCommandExecutionEvent, getAccCheck, getCommandContext, getCommandIfName, getCommandName, getCommandStoreId, getDefaultProperties, getExceptionInvokeParameters, getPostInvokeParameters, getPreInvokeParameters, getResources, getStoreId, getUser, getUserId, setAccCheck, setCommandContext, setCommandIfName, setCommandStoreId, setDefaultProperties, validateParameters
-
-
-
-
Constructor Detail
-
AddPromotionCodeToOrderCOTaskCmdImpl
public AddPromotionCodeToOrderCOTaskCmdImpl()
-
-
Method Detail
-
reset
public void reset()
Description copied from class:AbstractECTargetableCommand
This method is called after a command has been executed. It is used to reset its states variables. After the call to reset, the command should be able to be executed again.- Specified by:
reset
in interfacecom.ibm.websphere.command.Command
- Overrides:
reset
in classAbstractECTargetableCommand
- See Also:
AbstractECTargetableCommand.reset()
-
performExecute
public void performExecute() throws ECException
This method executes the business logic of this command implementation.The business logic of this command implementation is responsible for adding a promotion code to an order. *
- Specified by:
performExecute
in interfaceECCommand
- Specified by:
performExecute
in interfacecom.ibm.websphere.command.TargetableCommand
- Overrides:
performExecute
in classAbstractAddPromotionCodeToOrderTaskCmdImpl
- Throws:
ECException
- This exception is thrown when any kind of Exception catch.
-
setOrderId
public void setOrderId(java.lang.Long orderId)
This is the method to set order id. The order indicates which order need to added with unique promotion code.- Specified by:
setOrderId
in interfaceAddPromotionCodeToOrderTaskCmd
- Overrides:
setOrderId
in classAbstractAddPromotionCodeToOrderTaskCmdImpl
- Parameters:
orderId
- A Long representing the order id to be used in the command.
-
setPromotionCode
public void setPromotionCode(java.lang.String promotionCode)
This is the method to set promotion code. The promotion code indicates the promotion code which will add to an order.- Specified by:
setPromotionCode
in interfaceAddPromotionCodeToOrderTaskCmd
- Overrides:
setPromotionCode
in classAbstractAddPromotionCodeToOrderTaskCmdImpl
- Parameters:
promotionCode
- A String representing the promotion code to be used in the command.
-
setPromotionCodeType
public void setPromotionCodeType(java.lang.Short promotionCodeType)
Description copied from interface:AddPromotionCodeToOrderTaskCmd
This method sets the implementation type that is used for promotion code. 1 indicates the promotion code is implemented with unique promotion code framework.- Specified by:
setPromotionCodeType
in interfaceAddPromotionCodeToOrderTaskCmd
- Overrides:
setPromotionCodeType
in classAbstractAddPromotionCodeToOrderTaskCmdImpl
- Parameters:
promotionCodeType
- A Short representing the promotion code implementation type to be used in the command.- See Also:
AddPromotionCodeToOrderTaskCmd.setPromotionCodeType(java.lang.Short)
-
-