Save This Page
Home » struts-1.3.9-src » org.apache.struts » chain » commands » [javadoc | source]
org.apache.struts.chain.commands
public class: ExecuteCommand [javadoc | source]
java.lang.Object
   org.apache.struts.chain.commands.ActionCommandBase
      org.apache.struts.chain.commands.ExecuteCommand

All Implemented Interfaces:
    ActionCommand

Direct Known Subclasses:
    ExecuteForwardCommand

Invoke the appropriate Command for this request. If the context's ActionConfig has no command property defined, no action will be taken. If the specified command cannot be found, a warning will be logged, but processing will continue. Depending on how the chain is configured, this can be used in place of an Action or as a method of performing pre-processing.

If used instead of an action, the command which is looked up should put an ActionForward into the context, unless it has already dealt with the response.

Method from org.apache.struts.chain.commands.ExecuteCommand Summary:
execute,   getCommand,   getCommand,   shouldProcess
Methods from org.apache.struts.chain.commands.ActionCommandBase:
execute,   execute
Methods from java.lang.Object:
equals,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.apache.struts.chain.commands.ExecuteCommand Detail:
 public boolean execute(ActionContext actionCtx) throws Exception 

    If the context is "valid", lookup a command and execute it.

 protected Command getCommand(ActionContext context) 

    Find the ActionConfig in the current context and, if it is properly configured, lookup the appropriate commons-chain command.

 protected Command getCommand(String commandName,
    String catalogName) 

    Retrieve the specified Command from the specified Catalog.

 protected boolean shouldProcess(ActionContext context) 

    Evaluate the current context to see if a command should even be executed.