Skip navigation links

Oracle® Fusion Middleware Content Integration Suite (CIS) Java API Reference
11g Release 1 (11.1)

E17350-01


com.stellent.cis.client.command
Interface ICommand

All Superinterfaces:
java.lang.Cloneable, java.io.Serializable

public interface ICommand
extends java.io.Serializable, java.lang.Cloneable

Base interface for all commands. Commands are self-contained business-object units, based on the J2EE Command Design Pattern. Typically the client code will locate the bean through the com.stellent.cis.client.command.impl.CommandFacade#getCommand method then call the com.stellent.cis.client.command.impl.CommandFacade#getCommandExecutor to invoke the execute() method of the command object.


Method Summary
 java.lang.Object clone()
          Creates and returns a copy of this object.
 java.lang.Object execute()
          Execute this command.
 java.lang.String getCommandName()
          Get the name of this command
 ICommandExecutionContext getExecutionContext()
           
 java.lang.String getMethod()
          Get the method associated with this bean
 boolean isAsynchronous()
          Determine if this command should be executed asynchronously
 boolean isLocalInvocation()
           
 void setAsynchronous(boolean isAsynchronous)
          Set the asynchronous flag
 void setCommandName(java.lang.String name)
          Set the name of this command
 void setExecutionContext(ICommandExecutionContext executionContext)
          Set the execution context.
 void setLocalInvocation(boolean localInvocation)
          Set the flag that determines if the local or remote is executed
 void setMethod(java.lang.String method)
          Set the method name associated with this bean
 void setProperty(java.lang.String name, java.lang.Object value)
          Set a generic property on this command.

 

Method Detail

setProperty

void setProperty(java.lang.String name,
                 java.lang.Object value)
Set a generic property on this command.
Parameters:
name - the property name
value - the property value

getCommandName

java.lang.String getCommandName()
Get the name of this command
Returns:
the name of the command

setCommandName

void setCommandName(java.lang.String name)
Set the name of this command
Parameters:
name - the command name

getMethod

java.lang.String getMethod()
Get the method associated with this bean
Returns:
the method name associated with this bean

setMethod

void setMethod(java.lang.String method)
Set the method name associated with this bean
Parameters:
method - the method name

isAsynchronous

boolean isAsynchronous()
Determine if this command should be executed asynchronously
Returns:
true if this command should be executed asynchronously

setAsynchronous

void setAsynchronous(boolean isAsynchronous)
Set the asynchronous flag
Parameters:
isAsynchronous - set to true if this command should be executed asynchronously

setLocalInvocation

void setLocalInvocation(boolean localInvocation)
Set the flag that determines if the local or remote is executed
Parameters:
localInvocation - set to true if using the local interface, false otherwise

isLocalInvocation

boolean isLocalInvocation()
Returns:
true if using the local interface, false otherwise

execute

java.lang.Object execute()
                         throws CommandException
Execute this command. Typically called by the class that implements the ICommandExecutor interface.
Note: you must call setExecutionContext(ICommandExecutionContext) before calling this method.
Returns:
the result of this command call
Throws:
CommandException

getExecutionContext

ICommandExecutionContext getExecutionContext()
Returns:
the current execution context

setExecutionContext

void setExecutionContext(ICommandExecutionContext executionContext)
Set the execution context. Must be present before calling execute
Parameters:
executionContext - Must be present before calling execute()

clone

java.lang.Object clone()
                       throws java.lang.CloneNotSupportedException
Creates and returns a copy of this object. The precise meaning of "copy" may depend on the class of the object. The general intent is that, for any object x, the expression:
Returns:
a clone of this instance.
Throws:
java.lang.CloneNotSupportedException - if the object's class does not support the Cloneable interface. Subclasses that override the clone method can also throw this exception to indicate that an instance cannot be cloned.
java.lang.OutOfMemoryError - if there is not enough memory.
See Also:
Cloneable

Oracle® Fusion Middleware Content Integration Suite (CIS) Java API Reference
11g Release 1 (11.1)

E17350-01

Copyright © 1996, 2010, Oracle and/or its affiliates. All rights reserved.