public class DeployContractCmdImpl extends com.ibm.commerce.command.TaskCommandImpl implements DeployContractCmd
DeployContractCmd task command.
com.ibm.commerce.server.TransactionManager.begin();
com.ibm.commerce.server.TransactionManager.commit();
BusinessPolicyAccessBeanContractAccessBeancom.ibm.commerce.contract.objects.ContractJDBCHelperAccessBeanMemberAccessBeanMemberGroupAccessBeanOrganizationAccessBeanStoreDefaultAccessBeanTermConditionAccessBeanTradingAgreementAccessBeanUserAccessBean| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
CLASSNAME
The name of this class is "com.ibm.commerce.contract.commands.DeployContractCmdImpl".
|
static java.lang.String |
COPYRIGHT
The internal copyright field.
|
static java.lang.String |
PRICE_RULE_TC
Constant for price rule term condition.
|
static java.lang.String |
PRICE_RULE_TC_PROPERTY_BEGIN_DATE
Constant for the name of the price rule begin date property in the price
rule term condition.
|
static java.lang.String |
PRICE_RULE_TC_PROPERTY_EXPIRY_DATE
Constant for the name of the price rule expiry date property in the price
rule term condition.
|
static java.lang.String |
PRICE_RULE_TC_PROPERTY_RULE_ID
Constant for the name of the price rule identifier property in the price
rule term condition.
|
defaultCommandClassName, NAME| Constructor and Description |
|---|
DeployContractCmdImpl()
The default constructor
|
| Modifier and Type | Method and Description |
|---|---|
java.sql.Timestamp |
getCurrentTime(com.ibm.commerce.command.CommandContext commandContext)
Returns the current time from the command context.
|
com.ibm.commerce.contract.objects.ExtendedTermConditionAccessBean |
getValidPriceRuleExtendeTC(java.lang.Long contractID,
java.lang.Long memberID,
java.sql.Timestamp currentTime) |
boolean |
isValidDate(java.sql.Timestamp beginDate,
java.sql.Timestamp expiryDate,
java.sql.Timestamp currentTime)
Check whether the date is valid compared with the current time.
|
boolean |
isValidPriceRuleId(java.lang.String priceRuleId)
Check whether the price rule id is not empty
|
void |
performExecute()
Executes the business logic of this command implementation.
|
void |
setContractId(java.lang.Long newContractId)
Sets the contract Id
|
void |
setMaxContractNameLength(int maxLength)
Sets the Maximum length of the contract name.
|
void |
setRequestProperties(com.ibm.commerce.datatype.TypedProperty aRequestProperties)
Sets the requestProperties.
|
void |
setSynchronousDeployment(boolean synchronousDeploymentFlag)
Sets the synchronousDeployment flag to indicate contract should be deployed synchronously.
|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitaccessControlCheck, checkIsAllowed, checkResourcePermission, createCommandExecutionEvent, execute, getAccCheck, getCommandContext, getCommandIfName, getCommandName, getCommandStoreId, getDefaultProperties, getExceptionInvokeParameters, getObjectSize, getPostInvokeParameters, getPreInvokeParameters, getResources, getStoreId, getUser, getUserId, isReadyToCallExecute, reset, setAccCheck, setCommandContext, setCommandIfName, setCommandStoreId, setDefaultProperties, validateParameterscheckIsAllowed, checkResourcePermission, createCommandExecutionEvent, getAccCheck, getCommandContext, getCommandIfName, getCommandName, getCommandStoreId, getDefaultProperties, getExceptionInvokeParameters, getPostInvokeParameters, getPreInvokeParameters, getResources, getStoreId, getUser, getUserId, setAccCheck, setCommandContext, setCommandIfName, setCommandStoreId, setDefaultProperties, validateParameterspublic static final java.lang.String CLASSNAME
public static final java.lang.String COPYRIGHT
public static final java.lang.String PRICE_RULE_TC
public static final java.lang.String PRICE_RULE_TC_PROPERTY_BEGIN_DATE
public static final java.lang.String PRICE_RULE_TC_PROPERTY_EXPIRY_DATE
public static final java.lang.String PRICE_RULE_TC_PROPERTY_RULE_ID
public java.sql.Timestamp getCurrentTime(com.ibm.commerce.command.CommandContext commandContext)
commandContext - The command context. It may be null. If it is null, return the current
system time.public com.ibm.commerce.contract.objects.ExtendedTermConditionAccessBean getValidPriceRuleExtendeTC(java.lang.Long contractID,
java.lang.Long memberID,
java.sql.Timestamp currentTime)
throws com.ibm.commerce.exception.ECSystemException
com.ibm.commerce.exception.ECSystemExceptionpublic boolean isValidDate(java.sql.Timestamp beginDate,
java.sql.Timestamp expiryDate,
java.sql.Timestamp currentTime)
beginDate - The begin date. Can be null.expiryDate - The end date. Can be null.currentTime - The current time.public boolean isValidPriceRuleId(java.lang.String priceRuleId)
priceRuleId - The price rule id. Can be empty or null.public void performExecute()
throws com.ibm.commerce.exception.ECException
performExecute in interface com.ibm.commerce.command.ECCommandperformExecute in class com.ibm.commerce.command.AbstractECTargetableCommandcom.ibm.commerce.exception.ECExceptioncom.ibm.commerce.exception.ECSystemException - Raised with message _ERR_FINDER_EXCEPTION whenever a FinderException is occured
Raised with message _ERR_REMOTE_EXCEPTION whenever a RemoteException is occured
Raised with message _ERR_NAMING_EXCEPTION whenever a NamingException is occured
Raised with message _ERR_CREATE_EXCEPTION whenever a CreateException is occured
Raised with message _ERR_SQL_EXCEPTION whenever a SQLException is occured
Raised with message _ERR_PARSE_XML the contract XML cannot be parsed
Raised with message _ERR_CONTRACT_CMD_EXEC whenever an error is occuredAbstractECTargetableCommand.performExecute()public void setContractId(java.lang.Long newContractId)
newContractId - new contract idpublic void setMaxContractNameLength(int maxLength)
maxLength - The maximum length allowed for the contract namepublic void setRequestProperties(com.ibm.commerce.datatype.TypedProperty aRequestProperties)
throws com.ibm.commerce.exception.ECApplicationException
setRequestProperties in interface DeployContractCmdaRequestProperties - Request properties
EC_CONTRACT_ID and EC_TARGET_STORE_ID are both requiredcom.ibm.commerce.exception.ECApplicationException - Raised with message _ERR_MISSING_CMD_PARAMETER if the contract id or target store id is not specified in the
request propertiespublic void setSynchronousDeployment(boolean synchronousDeploymentFlag)
setSynchronousDeployment in interface DeployContractCmdsynchronousDeploymentFlag - true for synchronous deployment, false for asynchronous deployment