The command context contains session and user information. It is set in the controller command before the execute method is called
Field Summary | |
---|---|
static java.lang.String |
COPYRIGHT |
Method Summary | |
---|---|
java.lang.Long |
becomeUser(java.lang.Long userId) Become another user. |
java.lang.String |
buildRedirectUrl(TypedProperty prop) Returns a redirect url based on the properties. |
void |
changeStore(java.lang.Integer newValue) Changes the store and store associated information |
java.lang.Object |
clone() This method returns a clone of this command context. |
void |
generateLogId() Generate a Log Id. |
long |
getActivityId() Gets the activity ID associated with this command. |
boolean |
getAsyncCommand() Returns true if this command is an asynchronize command. |
boolean |
getClearForUser() Returns true if the parameter for clearing the for User Id is set. |
ECCommand |
getCommand() Gets the command associated with this command context. |
java.lang.String |
getCommandName() Gets the name of the command. |
java.lang.String |
getCountry() Gets the 2 character country code associated with this command. |
java.lang.String |
getCurrency() Gets the currency associated with this request. |
java.lang.String |
getCurrentCommandName() Gets the interface name of the current command. |
java.lang.String |
getCurrentTradingAgreementIdsAsString() Reserved for IBM internal use. |
TradingAgreementAccessBean[] |
getCurrentTradingAgreements() Gets the current set of trading agreements. |
java.lang.Integer |
getDefaultDeviceFormat() Gets the default device type. |
DeviceFormatAdapter |
getDeviceFormatAdapter() Gets the device format adapter associated with this command. |
java.lang.Integer |
getDeviceFormatId() Gets the device format id for the adapter associated with this request. |
java.lang.Integer |
getDeviceFormatTypeId() Gets the device type associated with this request. |
java.lang.Integer |
getDeviceType() Gets the device format type id for the adapter associated with this request. |
java.lang.String |
getDocumentPathName(java.lang.String baseName) Returns the actual output document path name give a base name |
java.lang.String[] |
getEligibleTradingAgreementIds() Gets the eligible trading agreemnt ids as an array. |
java.lang.String |
getEligibleTradingAgreementIdsAsString() Reserved for IBM internal use. |
java.lang.String |
getEncCurContr() Reserved for IBM internal use. |
java.lang.String |
getEncElgContr() Reserved for IBM internal use. |
java.lang.String |
getEncoding() Returns the character encoding. |
java.lang.String |
getEncParOrg() Reserved for IBM internal use. |
java.lang.String |
getEncParOrgAndCurContr() Reserved for IBM internal use. |
java.lang.String |
getEncSesContr() Reserved for IBM internal use. |
java.lang.String |
getErrorViewName() Gets the error view name. |
java.sql.Timestamp |
getExpiryDate() Gets the expiry date of a cached page. |
java.lang.Integer |
getForStoreId() Gets the forStoreId. |
java.lang.Long |
getForUserId() Gets the for user ID for this request. |
java.lang.Integer |
getInitialPreferredLanguage() Gets the preferred language Id for this request. |
java.lang.String |
getLanguage() Gets the 2 character language code associated with this command. |
java.lang.Integer |
getLanguageId() Gets the language Id associated with this request. |
java.util.Locale |
getLocale() Returns the locale associated with this request. |
java.util.Locale |
getLocale(java.lang.Integer languageId) Returns the locale associated with a given language. |
java.lang.String |
getLocaleVariant() Gets the locale variant associated with this request. |
long |
getLogId() Gets the Log id. |
StoreAccessBean |
getNonNullStore() Returns a non null store access bean object. |
java.lang.Long |
getOriginalUserId() Gets the user Id for the caller of this request. |
java.lang.String |
getParentOrg() Reserved for IBM internal use. |
java.lang.String |
getPreferredCurrency() Gets the preferred currency associated with this request. |
java.lang.Integer |
getPreferredLanguage() Gets the preferred language Id for this request. |
java.lang.String |
getRedirectionURL() Gets the redirect URL for this request. |
java.lang.String |
getRemoteAddr() Gets the address of the remote host. |
java.lang.String |
getRemoteHost() Gets the name of the remote host. |
java.lang.Object |
getRequest() Gets the controller request object associated with this request. |
TypedProperty |
getRequestProperties() Gets the request properties associated with this request. |
java.lang.String |
getResolvedQueryString() Gets the resolved request properties as a queryString. |
java.lang.Object |
getResponse() Gets the response object associated with this request. |
boolean |
getResult() Returns true when the command is successful. |
SessionContext |
getSessionContext() Return a session context associated with this request. |
SessionData |
getSessionData() Gets the sessionData associated with this request. |
java.lang.String |
getSessionTradingAgreementIdsAsString() Reserved for IBM internal use. |
StoreAccessBean |
getStore() Gets the Store Access Bean associated with this request. |
StoreAccessBean |
getStore(java.lang.Integer storeId) Returns a Store Access Bean give a store Id. |
java.lang.Integer |
getStoreId() Gets the store Id for this request. |
java.sql.Timestamp |
getTimestamp() Gets the timestamp when the request starts. |
TradingAgreementAccessBean |
getTradingAgreement(java.lang.Long id) Gets a trading agreement given an id. |
TradingAgreementAccessBean |
getTradingAgreement(java.lang.String id) Gets a trading agreement given an id. |
CustomProperties |
getTransactionCache() Gets the cache of custom properties. |
boolean |
getUncacheable() Returns true if page cannot be cached |
java.lang.String |
getUniqueSessionTag() Return a tag that is unique for the session. |
com.ibm.commerce.user.objects.UserAccessBean |
getUser() Gets the user access bean for the user of this request. |
java.lang.Long |
getUserId() Gets the user Id for the caller of this request. |
java.lang.String |
getViewCommand() Gets the view task associated with this command. |
java.lang.String |
getWebpath() Returns the web path for an Http request. |
void |
invalidateTradingAgreement(java.lang.Long id) Remove a trading agreement from cache. |
void |
invalidateTradingAgreement(java.lang.String id) Remove a trading agreement from cache. |
boolean |
isCacheTarget() Returns true if this command is a cache target. |
boolean |
isResponseNecessary() Returns true if response is necessary for this command. |
boolean |
isSecure() Returns true if this is an https commands and returns false otherwise. |
boolean |
isStoreCommand() Returns true if this is a store command. |
void |
resetStoreRef() Resets the EJB reference to the StoreAccessBean. |
void |
resetTradingAgreementInfo() Resets all trading agreement information. |
void |
restoreStore() Restore store and store associated information |
void |
restoreUser(java.lang.Long user) Restore to original user. |
void |
setActivityId(long newValue) Sets the activity ID associated with this command. |
void |
setAsyncCommand(boolean newValue) Sets the value to indicate whether this is an asynchronize command. |
void |
setCacheTarget(boolean newValue) Sets the isCacheTarget value for this command. |
void |
setCommand(ECCommand command) Sets the command associated with this command context. |
void |
setCommandName(java.lang.String value) Sets the command name. |
void |
setCountry(java.lang.String value) Sets the 2 character country code associated with this command. |
void |
setCurrency(java.lang.String value) Sets the currency to be used for this command. |
void |
setCurrentCommandName(java.lang.String name) Sets the interface name of the current command to be executed. |
void |
setCurrentTradingAgreements(TradingAgreementAccessBean[] contracts) Sets the current trading agreements. |
void |
setDefaultDeviceFormat(java.lang.Integer newValue) Sets the default device format type for this request. |
void |
setDeviceFormatAdapter(DeviceFormatAdapter newValue) Sets the device format adapter used for this request. |
void |
setDeviceFormatId(java.lang.Integer newValue) Sets the device format id for this request. |
void |
setDeviceFormatTypeId(java.lang.Integer newValue) Sets the device format type id for this request. |
void |
setDeviceType(java.lang.Integer newValue) Sets the device format type id for this request. |
void |
setEligibleTradingAgreementIdsAsString(java.lang.String newValue) Reserved for IBM internal use. |
void |
setEncCurContr(java.lang.String newValue) Reserved for IBM internal use. |
void |
setEncElgContr(java.lang.String newValue) Reserved for IBM internal use. |
void |
setEncoding(java.lang.String encoding) Sets the character encoding. |
void |
setEncParOrg(java.lang.String newValue) Reserved for IBM internal use. |
void |
setEncSesContr(java.lang.String newValue) Reserved for IBM internal use. |
void |
setErrorViewName(java.lang.String value) Sets the error view name. |
void |
setExpiryDate(java.sql.Timestamp newValue) Sets the expiry date for a cached page. |
void |
setForStoreId(java.lang.Integer val) Sets the forStoreId. |
void |
setForUserId(java.lang.Long value) Sets the for User Id for this request. |
void |
setLanguage(java.lang.String value) Sets the negotiated language for this command. |
void |
setLanguageId(java.lang.Integer newValue) Sets the negotiated language Id associated with this command. |
void |
setLocale(java.util.Locale newValue) Sets the locale for the command. |
void |
setLocaleVariant(java.lang.String value) Sets the locale variant to be used for this request. |
void |
setPreferredCurrency(java.lang.String value) Sets the preferred currency for the user for this command. |
void |
setPreferredLanguage(java.lang.Integer value) Sets the preferred language for this request. |
void |
setRedirectionURL(java.lang.String value) Sets the redirect URL name . |
void |
setRemoteAddr(java.lang.String newRemoteAddr) Sets the remote host address. |
void |
setRemoteHost(java.lang.String newRemoteHost) Sets the remote host name. |
void |
setRequest(java.lang.Object value) Sets the controller request object associated with this command. |
void |
setRequestProperties(TypedProperty prop) Sets the request property object associated with this request. |
void |
setResponse(java.lang.Object value) Sets the response object associated with this command. |
void |
setResponseNecessary(boolean newValue) Sets the isSecure value for this command. |
void |
setResult(boolean newValue) Sets the result for this command.This is for internal use by the framework only. |
void |
setSecure(boolean newValue) Sets the isSecure value for this command. |
void |
setSessionContext(SessionContext sessionContext) Sets the SessionContext object associated with this request. |
void |
setSessionData(SessionData sessionData) Sets the SessionData object associated with this request. |
void |
setSessionTradingAgreementIdsAsString(java.lang.String newValue) Reserved for IBM internal use. |
void |
setStore(StoreAccessBean newValue) Sets the store associated with this command. |
void |
setStoreCommand(boolean value) Sets the value for store command. |
void |
setStoreId(java.lang.Integer newValue) Sets the store Id associated with this command. |
void |
setTimestamp(java.sql.Timestamp value) Sets the timestamp for the comamnd. |
CustomProperties |
setTransactionCache(CustomProperties aCustomProperties) Sets the cache of custom properties. |
void |
setUncacheable(boolean newValue) Sets the value to indicate whether a page should be cached or not. |
void |
setUniqueSessionTag(java.lang.String value) Sets a tag that is unique for the session. |
void |
setUserId(java.lang.Long value) Sets the user Id for this request. |
void |
setViewCommand(java.lang.String value) Sets the view name for this command. |
void |
setWebpath(java.lang.String webpath) Sets the webpath associated with this command. |
boolean |
userCanExecuteCommand(
AccCommand command)
Reserved for IBM internal use. |
Field Detail |
public static final java.lang.String COPYRIGHT
Method Detail |
public java.lang.Long becomeUser(java.lang.Long userId)
public java.lang.String buildRedirectUrl(TypedProperty prop) throws ECApplicationException
prop
- TypedProperty - parameters for the redirect urlECApplicationException
public java.lang.Object clone()
public void generateLogId()
public long getActivityId()
public boolean getAsyncCommand()
public boolean getUncacheable()
public boolean getClearForUser()
public ECCommand getCommand()
public java.lang.String getCommandName()
public java.lang.String getCountry()
public java.lang.String getCurrency() throws ECSystemException
ECSystemException
public java.lang.String getCurrentCommandName()
public TradingAgreementAccessBean[] getCurrentTradingAgreements() throws ECException
ECException
public java.lang.Integer getDefaultDeviceFormat()
public DeviceFormatAdapter getDeviceFormatAdapter()
public java.lang.Integer getDeviceFormatId()
public java.lang.Integer getDeviceFormatTypeId()
public java.lang.Integer getDeviceType()
public java.lang.String getDocumentPathName(java.lang.String baseName)
baseName
- String - base name of the document
public java.lang.String[] getEligibleTradingAgreementIds() throws ECException
ECException
public java.lang.String getEligibleTradingAgreementIdsAsString()
public java.sql.Timestamp getExpiryDate()
public java.lang.Long getForUserId() throws ECException
ECException
public java.lang.Integer getInitialPreferredLanguage()
ECSystemException
public java.lang.String getLanguage()
public java.lang.Integer getLanguageId() throws ECSystemException
ECSystemException
public java.util.Locale getLocale()
public java.util.Locale getLocale(java.lang.Integer languageId)
public java.lang.String getLocaleVariant()
public long getLogId()
public StoreAccessBean getNonNullStore() throws ECSystemException
ECSystemException
public java.lang.Long getOriginalUserId()
public java.lang.String getPreferredCurrency() throws ECSystemException
ECSystemException
public java.lang.Integer getPreferredLanguage() throws ECSystemException
ECSystemException
public java.lang.String getRedirectionURL()
public java.lang.String getRemoteAddr()
public java.lang.String getRemoteHost()
public java.lang.Object getRequest()
public TypedProperty getRequestProperties()
public java.lang.String getResolvedQueryString()
public java.lang.Object getResponse()
public boolean getResult()
public SessionContext getSessionContext() throws ECException
ECException
public SessionData getSessionData()
public java.lang.String getSessionTradingAgreementIdsAsString() throws ECException
ECException
public StoreAccessBean getStore() throws ECSystemException
ECSystemException
public StoreAccessBean getStore(java.lang.Integer storeId) throws ECSystemException
ECSystemException
public java.lang.Integer getStoreId()
public java.sql.Timestamp getTimestamp()
public TradingAgreementAccessBean getTradingAgreement(java.lang.Long id) throws ECException
id
- Long - trading agreement id
ECException
public TradingAgreementAccessBean getTradingAgreement(java.lang.String id) throws ECException
id
- String - trading agreement id
ECException
public java.lang.String getUniqueSessionTag()
public com.ibm.commerce.user.objects.UserAccessBean getUser() throws ECSystemException
ECSystemException
public java.lang.Long getUserId()
public java.lang.String getViewCommand()
public java.lang.String getWebpath()
public void invalidateTradingAgreement(java.lang.Long id) throws ECException
id
- Long - trading agreement id.
ECException
public void invalidateTradingAgreement(java.lang.String id) throws ECException
id
- String - trading agreement id.
ECException
public boolean isCacheTarget()
public boolean isResponseNecessary()
public boolean isSecure()
public boolean isStoreCommand()
public void resetStoreRef()
public void resetTradingAgreementInfo()
public void restoreUser(java.lang.Long user)
user
- Long - original user Idpublic void setActivityId(long newValue)
public void setAsyncCommand(boolean newValue)
newValue
- boolean - true for asynchronize
commandpublic void setUncacheable(boolean newValue)
newValue
- booleanpublic void setCacheTarget(boolean newValue)
newValue
- booleanpublic void setCommand(ECCommand command)
command
- ECCommandpublic void setCommandName(java.lang.String value)
value
- language java.lang.Stringpublic void setCountry(java.lang.String value)
public void setCurrency(java.lang.String value)
public void setCurrentCommandName(java.lang.String name)
public void setCurrentTradingAgreements(TradingAgreementAccessBean[] contracts)
public void setDefaultDeviceFormat(java.lang.Integer newValue)
public void setDeviceFormatAdapter(DeviceFormatAdapter newValue)
public void setDeviceFormatId(java.lang.Integer newValue)
newValue
- java.lang.Integer - device format
idpublic void setDeviceFormatTypeId(java.lang.Integer newValue)
newValue
- java.lang.Integer - device format type
idpublic void setDeviceType(java.lang.Integer newValue)
newValue
- java.lang.Integer - device format type
idpublic void setEligibleTradingAgreementIdsAsString(java.lang.String newValue)
public void setExpiryDate(java.sql.Timestamp newValue)
newValue
- - TimeStamppublic void setForUserId(java.lang.Long value)
public void setLanguage(java.lang.String value)
value
- language java.lang.String - a 2 characeter String that
represents the languagepublic void setLanguageId(java.lang.Integer newValue)
newValue
- java.lang.Integerpublic void setLocale(java.util.Locale newValue)
public void setLocaleVariant(java.lang.String value)
value
- language java.lang.Stringpublic void setPreferredCurrency(java.lang.String value)
value
- java.lang.String - a characeter String that represents
the currencypublic void setPreferredLanguage(java.lang.Integer value)
public void setRedirectionURL(java.lang.String value)
value
- String - redirect URL namepublic void setRemoteAddr(java.lang.String newRemoteAddr)
public void setRemoteHost(java.lang.String newRemoteHost)
newRemoteHost
- java.lang.Stringpublic void setRequest(java.lang.Object value)
public void setRequestProperties(TypedProperty prop)
public void setResponse(java.lang.Object value)
value
- Object - response object.public void setResponseNecessary(boolean newValue)
newValue
- booleanpublic void setResult(boolean newValue)
newValue
- booleanpublic void setSecure(boolean newValue)
newValue
- booleanpublic void setSessionContext(SessionContext sessionContext)
sessionContext
- SessionContextpublic void setSessionData(SessionData sessionData)
sessionData
- SessionDatapublic void setSessionTradingAgreementIdsAsString(java.lang.String newValue)
public void setStore(StoreAccessBean newValue)
public void setStoreCommand(boolean value)
value
- booleanpublic void setStoreId(java.lang.Integer newValue)
public void setTimestamp(java.sql.Timestamp value)
value
- Timestamppublic void setUniqueSessionTag(java.lang.String value) throws ECException
value
- - java.lang.StringECException
public void setUserId(java.lang.Long value)
public void setViewCommand(java.lang.String value)
value
- String - view namepublic void setWebpath(java.lang.String webpath)
webpath
- Stringpublic boolean userCanExecuteCommand(AccCommand command) throws ECException
ECException
-
public java.lang.String getErrorViewName()
public void setErrorViewName(java.lang.String value)
value
- language java.lang.Stringpublic void changeStore(java.lang.Integer newValue)
public void restoreStore()
public void setEncElgContr(java.lang.String newValue)
newValue
- The eligible contractspublic java.lang.String getEncElgContr()
public java.lang.String getEncParOrgAndCurContr()
public java.lang.String getEncCurContr()
public java.lang.String getEncParOrg()
public java.lang.String getEncSesContr()
public void setEncCurContr(java.lang.String newValue)
newValue
- encrypted current contracts.
public void setEncParOrg(java.lang.String newValue)
newValue
- encrypted parent organization
public void setEncSesContr(java.lang.String newValue)
newValue
- encrypted session contract
public java.lang.String getCurrentTradingAgreementIdsAsString() throws ECException
ECException
public java.lang.String getParentOrg()
public java.lang.Integer getForStoreId()
public void setForStoreId(java.lang.Integer val)
val
- The forStoreIdpublic java.lang.String getEncoding()
public void setEncoding(java.lang.String encoding)
encoding
- The character encoding to setpublic CustomProperties getTransactionCache()
public CustomProperties setTransactionCache(CustomProperties aCustomProperties)