public class CommandFactory
extends java.lang.Object
Constructor and Description |
---|
CommandFactory()
This is the default constructor for this class.
|
Modifier and Type | Method and Description |
---|---|
static ECCommand |
createBusinessPolicyCommand(java.lang.Long policyId)
This method searches the policy command registry for an entry corresponding to the specified
policy id.
|
static ECCommand |
createBusinessPolicyCommand(java.lang.Long policyId,
java.lang.String interfaceName)
This method searches the policy command registry for an entry corresponding to the specified command
(interface) name and policy id.
|
static ECCommand |
createCommand(com.ibm.commerce.registry.CommandRegistryEntry cmdEntry)
This method instantiates an instance of a command based on the
CommandRegistryEntry information. |
static ECCommand |
createCommand(com.ibm.commerce.registry.CommandRegistryEntry cmdEntry,
java.lang.Integer storeId)
This method instantiates an instance of a command based on the
CommandRegistryEntry information. |
static ECCommand |
createCommand(java.lang.String cmdRefKey,
java.lang.Integer storeId)
This method searches the command registry for an entry corresponding to the specified command (interface) name
and storeId.
|
static ECCommand |
createCommand(java.lang.String cmdRefKey,
java.lang.Integer storeId,
boolean exceptionNeeded)
This method searches the command registry for an entry corresponding to the specified command (interface) name
and store id.
|
static ECCommand |
createViewCommand(com.ibm.commerce.registry.ViewRegistryEntry cmdEntry)
This method instantiates an instance of a view command based on the view registry entry information.
|
static ECCommand |
createViewCommand(com.ibm.commerce.registry.ViewRegistryEntry cmdEntry,
java.lang.Integer storeId)
This method instantiates an instance of a view command based on the view registry entry information.
|
static java.lang.String |
getCommandClassNameFromInterface(java.lang.String commandInterfaceName)
This method returns the default implementation of an interface.
|
static com.ibm.commerce.registry.CommandRegistryEntry |
locateCommandEntry(java.lang.String cmdRefKey,
java.lang.Integer storeId)
This method searches the command registry for an entry corresponding to the specified command (interface) name
and store id.
|
static com.ibm.commerce.registry.CommandRegistryEntry |
locateCommandEntry(java.lang.String cmdRefKey,
java.lang.Integer storeId,
boolean exceptionNeeded)
This method searches the command registry for an entry corresponding to the specified command (interface) name
and store id.
|
static com.ibm.commerce.registry.ViewRegistryEntry |
locateViewCommandEntry(java.lang.String cmdRefKey,
java.lang.Integer storeId,
java.lang.Integer deviceFmt)
This method searches the view registry for an entry corresponding to the specified view name,
store id and device type.
|
static com.ibm.commerce.registry.ViewRegistryEntry |
locateViewCommandEntry(java.lang.String cmdRefKey,
java.lang.Integer storeId,
java.lang.Integer deviceFmt,
boolean exceptionNeeded)
This method searches the view registry for an entry corresponding to the specified view name,
store id and device type.
|
static com.ibm.commerce.registry.ViewRegistryEntry |
locateViewCommandEntry(java.lang.String cmdRefKey,
java.lang.Integer storeId,
java.lang.Integer deviceFmt,
java.lang.Integer dftDeviceFmt)
This method searches the view registry for an entry corresponding to the specified view name,
store id and device type.
|
static com.ibm.commerce.registry.ViewRegistryEntry |
locateViewCommandEntry(java.lang.String cmdRefKey,
java.lang.Integer storeId,
java.lang.Integer deviceFmt,
java.lang.Integer dftDeviceFmt,
boolean exceptionNeeded)
This method searches the view registry for an entry corresponding to the specified view name,
store id, and device type.
|
static com.ibm.commerce.registry.ViewRegistryEntry |
locateViewCommandEntry(java.lang.String cmdRefKey,
java.lang.Integer storeId,
java.lang.Integer deviceFmt,
java.lang.Integer dftDeviceFmt,
boolean exceptionNeeded,
javax.servlet.http.HttpServletRequest request)
This method searches the view registry for an entry corresponding to the specified view name,
store id, and device type.
|
static void |
setCommandRegistry(com.ibm.commerce.registry.CommandRegistry newValue)
This method sets the command registry to be used by the command factory to locate commands.
|
static void |
setViewRegistry(com.ibm.commerce.registry.ViewRegistry newValue)
This method sets the view registry to be used by the command factory to locate commands.
|
public CommandFactory()
public static ECCommand createBusinessPolicyCommand(java.lang.Long policyId) throws ECException
policyId
- This is a Long
object that represents a policy id.ECException
public static ECCommand createBusinessPolicyCommand(java.lang.Long policyId, java.lang.String interfaceName) throws ECException
interfaceName
- This is a String
object that represents a command interface name.policyId
- This is a Long
object that represents a policy id.ECException
public static ECCommand createCommand(com.ibm.commerce.registry.CommandRegistryEntry cmdEntry) throws ECException
CommandRegistryEntry
information.cmdEntry
- This is a CommandRegistryEntry
object that represents a command registry entry.ECException
public static ECCommand createCommand(com.ibm.commerce.registry.CommandRegistryEntry cmdEntry, java.lang.Integer storeId) throws ECException
CommandRegistryEntry
information.comdEntry
- This is a CommandRegistryEntry
object that represents a command registry entry.storeId
- Ths is an Integer
object that represents the store id associated with the command.ECException
public static ECCommand createCommand(java.lang.String cmdRefKey, java.lang.Integer storeId) throws ECException
cmdRefKey
- This is a String
object that represents a command interface name.storeId
- This is an Integer
object that represents the store id associated with the command.ECException
public static ECCommand createViewCommand(com.ibm.commerce.registry.ViewRegistryEntry cmdEntry) throws ECException
cmdEntry
- This is a ViewRegistryEntry
object.ECException
public static ECCommand createViewCommand(com.ibm.commerce.registry.ViewRegistryEntry cmdEntry, java.lang.Integer storeId) throws ECException
cmdEntry
- This is a ViewRegistryEntry
object.storeId
- This is an Integer
object that represents the store id associated with the command.ECException
public static java.lang.String getCommandClassNameFromInterface(java.lang.String commandInterfaceName)
commandInterfaceName
- This is the command interface name.String
representation of the default implementation class
name if defined.public static com.ibm.commerce.registry.CommandRegistryEntry locateCommandEntry(java.lang.String cmdRefKey, java.lang.Integer storeId) throws ECException
cmdRefKey
- This is a String
object that represents a command interface name.storeId
- This is an Integer
object that represents the store id associated with the command.ECException
public static void setCommandRegistry(com.ibm.commerce.registry.CommandRegistry newValue)
newValue
- This is a CommandRegistry
object.public static void setViewRegistry(com.ibm.commerce.registry.ViewRegistry newValue)
newValue
- This is a ViewRegistry
object.public static com.ibm.commerce.registry.ViewRegistryEntry locateViewCommandEntry(java.lang.String cmdRefKey, java.lang.Integer storeId, java.lang.Integer deviceFmt, java.lang.Integer dftDeviceFmt, boolean exceptionNeeded) throws ECException
ECException
is thrown if no matching entry is found.cmdRefKey
- This is a String
object that represents name of the view.storeId
- This is an Integer
object that represents the store id associated with the command.deviceFmt
- This is an Integer
object that represents the device format type id.dftDeviceFmt
- This is an Integer
object that represents the default device format type id.exceptionNeeded
- This is a boolean
value that indicates whether an exception will be thrown when the entry cannot be found.ECException
- This is thrown if no matching entry is found.public static com.ibm.commerce.registry.ViewRegistryEntry locateViewCommandEntry(java.lang.String cmdRefKey, java.lang.Integer storeId, java.lang.Integer deviceFmt, boolean exceptionNeeded) throws ECException
ECException
is thrown if no matching entry is found.cmdRefKey
- This is a String
object that represents name of the view.storeId
- This is an Integer
object that represents the store id associated with the command.deviceFmt
- This is an Integer
object that represents the device format type id.exceptionNeeded
- This is a boolean
value that indicates whether an exception will be thrown when the entry cannot be found.ECException
- Thrown if no matching entry is found.public static ECCommand createCommand(java.lang.String cmdRefKey, java.lang.Integer storeId, boolean exceptionNeeded) throws ECException
cmdRefKey
- This is a String
object that represents a command interface name.storeId
- This is an Integer
object that represents the store id associated with the command.exceptionNeeded
- This is a boolean
value that indicates whether an exception will be thrown when the entry cannot be found.ECException
public static com.ibm.commerce.registry.CommandRegistryEntry locateCommandEntry(java.lang.String cmdRefKey, java.lang.Integer storeId, boolean exceptionNeeded) throws ECException
cmdRefKey
- This is a String
object that represents a command interface name.storeId
- This is an Integer
object that represents the store id associated with the command.exceptionNeeded
- This is a boolean
value that indicates whether an exception will be thrown when the entry cannot be found.ECException
public static com.ibm.commerce.registry.ViewRegistryEntry locateViewCommandEntry(java.lang.String cmdRefKey, java.lang.Integer storeId, java.lang.Integer deviceFmt) throws ECException
ECException
is thrown if no matching entry is found.cmdRefKey
- This is a String
object that represents name of the view.storeId
- This is an Integer
object that represents the store id associated with the command.deviceFmt
- This is an Integer
object that represents the device format type id.ECException
- This is thrown if no matching entry is found.public static com.ibm.commerce.registry.ViewRegistryEntry locateViewCommandEntry(java.lang.String cmdRefKey, java.lang.Integer storeId, java.lang.Integer deviceFmt, java.lang.Integer dftDeviceFmt) throws ECException
ECException
is thrown if no matching entry is found.cmdRefKey
- This is a String
object that represents name of the view.storeId
- This is an Integer
object that represents the store id associated with the command.deviceFmt
- This is an Integer
object that represents the device format type id.dftDeviceFmt
- This is an Integer
object that represents the default device format type id.ECException
- This is thrown if no matching entry is found.public static com.ibm.commerce.registry.ViewRegistryEntry locateViewCommandEntry(java.lang.String cmdRefKey, java.lang.Integer storeId, java.lang.Integer deviceFmt, java.lang.Integer dftDeviceFmt, boolean exceptionNeeded, javax.servlet.http.HttpServletRequest request) throws ECException
ECException
is thrown if no matching entry is found.cmdRefKey
- This is a String
object that represents name of the view.storeId
- This is an Integer
object that represents the store id associated with the command.deviceFmt
- This is an Integer
object that represents the device format type id.dftDeviceFmt
- This is an Integer
object that represents the default device format type id.exceptionNeeded
- This is a boolean
value that indicates whether an exception will be thrown when the entry cannot be found.request
- the HTTPServletRequestECException
- This is thrown if no matching entry is found.