|
IBM WebSphere Application ServerTM Release 8 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface TargetableCommand
The TargetableCommand interface describes a command that can be run in a remote JVM. It extends the Command interface and declares methods that support remote execution of commands. Some of the methods are implemented in the TargetableCommandImpl class, and some must be implemented by the application programmer.
A targetable command must have a target, which represents the server that will actually run the command. The target object is an instance of the CommandTarget interface, and it is responsible for ensuring that the command runs in the desired server environment. For each server, there is at least one class that implements the CommandTarget interface.
The TargetableCommand interface provides two ways for a client to specify the target of a command:
Field Summary |
---|
Fields inherited from interface com.ibm.websphere.command.Command |
---|
serialVersionUID |
Method Summary | |
---|---|
CommandTarget |
getCommandTarget()
Returns the target object for the command. |
java.lang.String |
getCommandTargetName()
Returns the name of the target object for the command. |
boolean |
hasOutputProperties()
Indicates if the command has any output properties that must be returned to the client. |
void |
performExecute()
Runs the business logic that makes up the command. |
void |
setCommandTarget(CommandTarget commandTarget)
Sets the target object on the command. |
void |
setCommandTargetName(java.lang.String commandTargetName)
Sets the name of the target object on the command. |
void |
setOutputProperties(TargetableCommand fromCommand)
Sets the return values on the command. |
Methods inherited from interface com.ibm.websphere.command.Command |
---|
execute, isReadyToCallExecute, reset |
Method Detail |
---|
CommandTarget getCommandTarget()
This method is implemented in the TargetableCommandImpl class.
java.lang.String getCommandTargetName()
This abstract is implemented in the TargetableCommandImpl class.
boolean hasOutputProperties()
false
to
eliminate unecessary copying and remote invocations.
This method is implemented in the TargetableCommandImpl class.
true
if the command has output properties.void performExecute() throws java.lang.Exception
This method must be implemented by the application programmer.
java.lang.Exception
- Any exception that occurs in the method will be thrown
as an Exception.void setCommandTarget(CommandTarget commandTarget)
This method is implemented in the TargetableCommandImpl class.
commandTarget
- The target object for the command.void setCommandTargetName(java.lang.String commandTargetName)
This method is implemented in the TargetableCommandImpl class.
commandTargetName
- The name of the target object for the command.
The name is a fully qualified name for a Java
class, for example, mypkg.bp.MyBusinessCmdTarget.void setOutputProperties(TargetableCommand fromCommand)
false
, there is no need to invoke this method.
This method is implemented in the TargetableCommandImpl class.
fromCommand
- The command from which the output properties are copied.
|
IBM WebSphere Application ServerTM Release 8 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |