com.ibm.commerce.interestitems.commands
Class InterestItemDisplayCmdImpl
- 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.ControllerCommandImpl
-
- com.ibm.commerce.interestitems.commands.InterestItemDisplayCmdImpl
-
- All Implemented Interfaces:
- AccCommand, ControllerCommand, ECCommand, ECTargetableCommand, InterestItemDisplayCmd, Protectable, 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 InterestItemDisplayCmdImpl extends ControllerCommandImpl implements InterestItemDisplayCmd
The InterestItemDisplay command displays a list or lists of all the products and items in the specified interest item lists. Note: Use this command in conjunction with SSL (Secure Sockets Layer), to ensure that the shopper's logon password and personal information are encrypted. SSL is the default.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field and Description static java.lang.String
CLASSNAME
The fully qualified name of this class.static java.lang.String
COPYRIGHT
The internal copyright field.-
Fields inherited from interface com.ibm.commerce.interestitems.commands.InterestItemDisplayCmd
defaultCommandClassName, NAME
-
-
Constructor Summary
Constructors Constructor and Description InterestItemDisplayCmdImpl()
No value constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description void
checkIsAllowed(AccessVector resource, java.lang.String action)
Check to see if user can perform action on resource.java.lang.Long[]
getResourceOwners()
This method gets all the organization units that own the resources accessed by this command.boolean
isReadyToCallExecute()
This method is called by the targetable command framework.void
performExecute()
The main program for InterestItemDisplayCmd command.void
reset()
This method is called after a command has been executed.void
setListId(java.lang.String[] asaListId)
Specifies zero or more interest item lists to be displayed.void
setListIdName(java.lang.String[] asaListIdName)
Specifies the names of name-value pairs to be added to the redirection URL.void
setListMemberId(java.lang.Long anListMemberId)
The id of the member whose interest lists will be displayed.void
setRequestProperties(TypedProperty aRequestProperties)
This method sets therequestProperties
for the command.void
validateParameters()
This method performs server side parameter checking.-
Methods inherited from class com.ibm.commerce.command.ControllerCommandImpl
checkPermission, fulfills, getForUserId, getGeneric, getOwner, getRequestProperties, getResolvedRequestProperties, getResponseProperties, getRetriable, getViewInputProperties, isGeneric, isRetriable, mergeProperties, setForUserId, setGeneric, setOwner, setResponseProperties, setRetriable, setViewInputProperties
-
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, 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.commerce.command.ControllerCommand
checkPermission, execute, getGeneric, getRequestProperties, getResolvedRequestProperties, getResponseProperties, getRetriable, getViewInputProperties, isGeneric, isRetriable, mergeProperties, setGeneric, setRetriable, setViewInputProperties
-
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.AccCommand
accessControlCheck, getAccCheck, getForUserId, setAccCheck, setForUserId, setOwner
-
Methods inherited from interface com.ibm.commerce.command.ECCommand
checkIsAllowed, checkResourcePermission, createCommandExecutionEvent, getCommandContext, getCommandIfName, getCommandName, getCommandStoreId, getDefaultProperties, getExceptionInvokeParameters, getPostInvokeParameters, getPreInvokeParameters, getResources, getStoreId, getUser, getUserId, setCommandContext, setCommandIfName, setCommandStoreId, setDefaultProperties
-
Methods inherited from interface com.ibm.commerce.security.Protectable
fulfills, getOwner
-
-
-
-
Field Detail
-
COPYRIGHT
public static final java.lang.String COPYRIGHT
The internal copyright field.- See Also:
- Constant Field Values
-
CLASSNAME
public static final java.lang.String CLASSNAME
The fully qualified name of this class.- See Also:
- Constant Field Values
-
-
Constructor Detail
-
InterestItemDisplayCmdImpl
public InterestItemDisplayCmdImpl()
No value constructor.
-
-
Method Detail
-
checkIsAllowed
public void checkIsAllowed(AccessVector resource, java.lang.String action) throws ECException
Check to see if user can perform action on resource. This is called by the command to perform resource level access control check in addition to the resources returned by the getResources() method.- Parameters:
resource
- AccessVector - the resource to be acted onaction
- String - action to be performed on the resource- Throws:
ECException
-
getResourceOwners
public java.lang.Long[] getResourceOwners() throws ECException
Description copied from class:ControllerCommandImpl
This method gets all the organization units that own the resources accessed by this command. It returns null if no resource is being accessed by this command. This method was used in WebSphere Commerce 5.1 for command level access control checking. It is no longer required. It is kept for backward compatibility. The default implementation returns null.- Specified by:
getResourceOwners
in interfaceAccCommand
- Overrides:
getResourceOwners
in classControllerCommandImpl
- Returns:
- This method returns an array of
Long
objects that represents all the organization unit reference numbers. A site owner is represented by an organization unit value of -1. - Throws:
ECException
-
isReadyToCallExecute
public boolean isReadyToCallExecute()
Description copied from class:AbstractECTargetableCommand
This method is called by the targetable command framework. This is where client side parameter checking is performed (before the execution of the command). The default implementation is to returntrue
.- Specified by:
isReadyToCallExecute
in interfacecom.ibm.websphere.command.Command
- Overrides:
isReadyToCallExecute
in classAbstractECTargetableCommand
- Returns:
- This method returns a
boolean
value;true
if we can execute the command andfalse
otherwise. This default implementation will returntrue
.
-
performExecute
public void performExecute() throws ECException
The main program for InterestItemDisplayCmd command. This method displays interest items.- Specified by:
performExecute
in interfaceECCommand
- Specified by:
performExecute
in interfacecom.ibm.websphere.command.TargetableCommand
- Overrides:
performExecute
in classAbstractECTargetableCommand
- Throws:
ECException
-
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
-
setListId
public void setListId(java.lang.String[] asaListId)
Specifies zero or more interest item lists to be displayed. In addition to interest item list reference numbers it can be specified as one of the special abbreviations ".", "*". Sets the interest item list ID parameters (optional with default "."). If "." is specified, the GetCurrentIILists process task is invoked to obtain the shopper's current interest item lists, and the command behaves as if the current interest item lists were specified. If GetCurrentIILists process task determines that there are no current interest item lists, the most recently updated item interest item list is used. If "*" is specified, the command behaves as if all shopper's interest item lists were specified. If this parameter is missing, this command behaves as if "." were specified.- Specified by:
setListId
in interfaceInterestItemDisplayCmd
- Parameters:
asaListId
- the ListId
-
setListIdName
public void setListIdName(java.lang.String[] asaListIdName)
Specifies the names of name-value pairs to be added to the redirection URL. The values of the added name-value pairs are the reference numbers of the interest lists specified by ListId. This is provided to make it possible to obtain the reference numbers of the interest lists when ListId is not explicitly specified.- Specified by:
setListIdName
in interfaceInterestItemDisplayCmd
- Parameters:
asaListIdName
- the array of names
-
setListMemberId
public void setListMemberId(java.lang.Long anListMemberId)
The id of the member whose interest lists will be displayed. If this parameter is not specified, the default is the current member.- Specified by:
setListMemberId
in interfaceInterestItemDisplayCmd
- Parameters:
anListMemberId
- the member id
-
setRequestProperties
public void setRequestProperties(TypedProperty aRequestProperties) throws ECApplicationException
Description copied from class:ControllerCommandImpl
This method sets therequestProperties
for the command. TheWebController
calls thesetRequestProperties
method before invoking the execute method for this command. It is the responsibility of the command writer to extract the required input parameters from therequestProperties
object.- Specified by:
setRequestProperties
in interfaceControllerCommand
- Overrides:
setRequestProperties
in classControllerCommandImpl
- Parameters:
aRequestProperties
- This is an object that represents the request properties.- Throws:
ECApplicationException
-
validateParameters
public void validateParameters() throws ECException
Description copied from class:AbstractECTargetableCommand
This method performs server side parameter checking. This method replaces thecheckParameters()
method from version 5.1. The default implementation ofvalidateParameters()
is ano op
. It is the responsibility of the command writers to implement this method if they want to perform server side parameter checking.- Specified by:
validateParameters
in interfaceECCommand
- Overrides:
validateParameters
in classAbstractECTargetableCommand
- Throws:
ECException
-
-