|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Object | +--com.ibm.workflow.servlet.client.Command
This class encapsulates what commands are allowed in the various states of
process templates,
process instances,
activity instances,
persistent lists,
and work items.
It also holds the default image names for the commands.
See also the HTMLDocHandler and
AuditTrailHandler samples
for how to use this class in custom handlers.
| Field Summary | |
static Command |
AI_FORCE_FINISH
Command for ActivityInstance#forceFinish |
static Command |
AI_FORCE_RESTART
Command for ActivityInstance#forceRestart |
static Command |
AI_SHOW_PROPERTIES
Command to show activity properties |
static Command |
AI_TERMINATE
Command for ActivityInstance.terminate() |
static Command |
ITEM_DELETE
Command for Item.delete() |
static Command |
ITEM_TRANSFER
Command for Item.transfer(java.lang.String) |
static Command |
LIST_DELETE
Command for PersistentList.delete() |
static Command |
LIST_QUERY_LISTS
Command to query all persistent lists |
static Command |
LIST_SHOW_PROPERTIES
Command to show a persistent list's properties |
static Command |
PI_DELETE
Command for ProcessInstance.delete() |
static Command |
PI_RESTART
Command for ProcessInstance.restart() |
static Command |
PI_RESUME
Command for ProcessInstance.resume(boolean) |
static Command |
PI_SHOW_MONITOR
Command to show a process instance monitor |
static Command |
PI_SHOW_PROPERTIES
Command to show process instance properties |
static Command |
PI_START
Command for ProcessInstance.start() |
static Command |
PI_SUSPEND
Command for ProcessInstance.suspend(boolean) |
static Command |
PI_TERMINATE
Command for ProcessInstance.terminate() |
static Command |
PIL_QUERY_INSTANCES
Command for ProcessInstanceList.queryProcessInstances() |
static Command |
PT_CREATE_AND_START_INSTANCE
Command for ProcessTemplate.createAndStartInstance(java.lang.String, java.lang.String, java.lang.String, boolean) |
static Command |
PT_CREATE_INSTANCE
Command for ProcessTemplate.createInstance(java.lang.String, java.lang.String, java.lang.String, boolean) |
static Command |
PT_DELETE
Command for ProcessTemplate.delete() |
static Command |
PT_SHOW_PROPERTIES
Command to show process template properties |
static Command |
PTL_QUERY_TEMPLATES
Command for ProcessTemplateList.queryProcessTemplates() |
static Command |
WI_CANCEL_CHECKOUT
Command for WorkItem.cancelCheckOut() |
static Command |
WI_CHECKIN
Command for WorkItem.checkIn(com.ibm.workflow.api.ReadWriteContainer, int) |
static Command |
WI_CHECKOUT
Command for WorkItem.checkOut() |
static Command |
WI_FINISH
Command for WorkItem.finish() |
static Command |
WI_FORCE_FINISH
Command for WorkItem.forceFinish() |
static Command |
WI_FORCE_RESTART
Command for WorkItem.forceRestart() |
static Command |
WI_RESTART
Command for WorkItem.restart() |
static Command |
WI_SHOW_PROPERTIES
Command to show work item properties |
static Command |
WI_START
Command for WorkItem.start() |
static Command |
WI_TERMINATE
Command for WorkItem.terminate() |
static Command |
WL_QUERY_WORK_ITEMS
Command for WorkList.queryWorkItems() |
| Constructor Summary | |
Command(java.lang.String commandString,
java.lang.String commandPicture,
java.lang.String commandText)
Constructs a Command object. |
|
Command(java.lang.String commandString,
java.lang.String commandPrompt,
java.lang.String commandParameter,
java.lang.String commandPicture,
java.lang.String commandText)
Constructs a Command object. |
|
| Method Summary | |
java.lang.String |
getActionButton(RequestContext context,
java.lang.String imageAttr)
Creates an img tag pointing to the action button for this
command (<documentRoot>/images/navigation/<commandPicture>). |
java.lang.String |
getActionIcon(RequestContext context,
java.lang.String imageAttr)
Creates an img tag pointing to the action icon for this
command (<documentRoot>/images/action/<commandPicture>). |
static Command[] |
getActions(ActivityInstance activity)
Get the list of allowed commands for an activity instance. |
static Command[] |
getActions(ActivityInstanceNotification item)
Get the list of allowed commands for a activity notification item. |
static Command[] |
getActions(PersistentList list)
Get the list of allowed commands for a persistent list. |
static Command[] |
getActions(ProcessInstance instance)
Get the list of allowed commands for a process instance. |
static Command[] |
getActions(ProcessInstanceNotification item)
Get the list of allowed commands for a process notification item. |
static Command[] |
getActions(ProcessTemplate template)
Get the list of allowed commands for a process template. |
static Command[] |
getActions(java.lang.String user,
WorkItem workItem)
Get the list of allowed commands for a work item. |
java.lang.String |
getCommand()
Query the command string. |
java.lang.String |
getText(SessionContext cat)
Query the command's text that can be used as alt text
or as button label. |
java.lang.String |
getTriggerTag(RequestContext context,
java.lang.String id,
java.lang.String name)
Construct a HTML anchor ( a href) tag that will cause the
command to be executed. |
java.lang.String |
getURL(RequestContext context,
java.lang.String id,
java.lang.String name,
boolean hrefClick)
Construct a URL that will cause the command to be executed. |
Command |
withParameter(java.lang.String commandParameter)
Creates a new command with the same attributes and a new parameter. |
Command |
withPrompt(java.lang.String commandPrompt,
java.lang.String commandParameter)
Creates a new command with the same attributes and a new prompt. |
Command |
withText(java.lang.String commandText)
Creates a new command with the same attributes and a new text. |
| Methods inherited from class java.lang.Object |
equals,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
| Field Detail |
public static final Command LIST_QUERY_LISTS
public static final Command LIST_DELETE
PersistentList.delete()public static final Command LIST_SHOW_PROPERTIES
public static final Command PTL_QUERY_TEMPLATES
ProcessTemplateList.queryProcessTemplates()public static final Command PIL_QUERY_INSTANCES
ProcessInstanceList.queryProcessInstances()public static final Command WL_QUERY_WORK_ITEMS
WorkList.queryWorkItems()public static final Command PT_CREATE_AND_START_INSTANCE
ProcessTemplate.createAndStartInstance(java.lang.String, java.lang.String, java.lang.String, boolean)public static final Command PT_CREATE_INSTANCE
ProcessTemplate.createInstance(java.lang.String, java.lang.String, java.lang.String, boolean)public static final Command PT_DELETE
ProcessTemplate.delete()public static final Command PT_SHOW_PROPERTIES
public static final Command PI_DELETE
ProcessInstance.delete()public static final Command PI_RESTART
ProcessInstance.restart()public static final Command PI_RESUME
ProcessInstance.resume(boolean)public static final Command PI_START
ProcessInstance.start()public static final Command PI_SUSPEND
ProcessInstance.suspend(boolean)public static final Command PI_TERMINATE
ProcessInstance.terminate()public static final Command PI_SHOW_PROPERTIES
public static Command PI_SHOW_MONITOR
public static final Command AI_FORCE_FINISH
ActivityInstance#forceFinishpublic static final Command AI_FORCE_RESTART
ActivityInstance#forceRestartpublic static final Command AI_SHOW_PROPERTIES
public static final Command AI_TERMINATE
ActivityInstance.terminate()public static final Command ITEM_DELETE
Item.delete()public static final Command ITEM_TRANSFER
Item.transfer(java.lang.String)public static final Command WI_CANCEL_CHECKOUT
WorkItem.cancelCheckOut()public static final Command WI_CHECKIN
WorkItem.checkIn(com.ibm.workflow.api.ReadWriteContainer, int)public static final Command WI_CHECKOUT
WorkItem.checkOut()public static final Command WI_FINISH
WorkItem.finish()public static final Command WI_FORCE_FINISH
WorkItem.forceFinish()public static final Command WI_FORCE_RESTART
WorkItem.forceRestart()public static final Command WI_RESTART
WorkItem.restart()public static final Command WI_START
WorkItem.start()public static final Command WI_TERMINATE
WorkItem.terminate()public static final Command WI_SHOW_PROPERTIES
| Constructor Detail |
public Command(java.lang.String commandString,
java.lang.String commandPicture,
java.lang.String commandText)
commandString - the command to be invokedcommandPicture - the name of the .gif file to be shown
(see getActionIcon and
getActionButton)commandText - the description of the command (used for example
as alt text or button label)
public Command(java.lang.String commandString,
java.lang.String commandPrompt,
java.lang.String commandParameter,
java.lang.String commandPicture,
java.lang.String commandText)
commandString - the command to be invokedcommandPrompt - the question to be prompted before the command
is invoked; may be nullcommandParameter - any additional parameter that is to be passed
to the command when it is invoked; may be
nullcommandPicture - the name of the .gif to be showncommandText - the description of the command (used for example
as alt text or button label)| Method Detail |
public Command withParameter(java.lang.String commandParameter)
commandParameter - the new command's parameter
public Command withPrompt(java.lang.String commandPrompt,
java.lang.String commandParameter)
commandPrompt - the new command's promptcommandParameter - the new command's parameterpublic Command withText(java.lang.String commandText)
text.commandText - the new command's textpublic java.lang.String getCommand()
public java.lang.String getText(SessionContext cat)
alt text
or as button label.context - the context to be used for localized strings
public java.lang.String getTriggerTag(RequestContext context,
java.lang.String id,
java.lang.String name)
a href) tag that will cause the
command to be executed. This tag will contain JavaScript code if a
client-side prompt is needed. For example, the
BuiltinHandler.deleteTemplate()
command will prompt before actually deleting the template.context - the request contextid - the OID of the object on which the command should be
invokedname - the name of the object (only used in JavaScript prompts)a href tag
public java.lang.String getURL(RequestContext context,
java.lang.String id,
java.lang.String name,
boolean hrefClick)
BuiltinHandler.deleteTemplate() command will prompt before actually
deleting the template.context - the request contextid - the OID of the object on which the command should be
invokedname - the name of the object (only used in JavaScript prompts)hrefClick - indicates if the URL is to be used for a
href onClick argument
public java.lang.String getActionIcon(RequestContext context,
java.lang.String imageAttr)
img tag pointing to the action icon for this
command (<documentRoot>/images/action/<commandPicture>).
This icon is typically used in list rows.context - the request contextimageAttr - any additional image attribute (for example,
border="0")img HTML code for the action image
public java.lang.String getActionButton(RequestContext context,
java.lang.String imageAttr)
img tag pointing to the action button for this
command (<documentRoot>/images/navigation/<commandPicture>).
This button is typically used in navigation bars.context - the request contextimageAttr - any additional image attribute (for example,
border="0")img HTML code for the action button
public static Command[] getActions(ProcessTemplate template)
throws FmcException
null, but may be empty.template - the process template for which the allowed commands
are queried
public static Command[] getActions(ProcessInstance instance)
throws FmcException
null, but may be empty.instance - the process instance for which the allowed commands
are queried
public static Command[] getActions(ActivityInstance activity)
throws FmcException
null, but may be empty.activity - the activity instance for which the allowed commands
are queriedpublic static Command[] getActions(ProcessInstanceNotification item)
item - the process notification item for which the allowed commands
are queriedpublic static Command[] getActions(ActivityInstanceNotification item)
item - the activity notification item for which the allowed commands
are queried
public static Command[] getActions(PersistentList list)
throws FmcException
null, but may be empty.list - the persistent list for which the allowed commands
are queried
public static Command[] getActions(java.lang.String user,
WorkItem workItem)
throws FmcException
null, but may be empty.user - the ID of the current userworkItem - the work item for which the allowed commands
are queried
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||