| java.lang.Object org.springframework.webflow.engine.AnnotatedObject org.springframework.webflow.engine.AnnotatedAction
AnnotatedAction | public class AnnotatedAction extends AnnotatedObject implements Action(Code) | | An action proxy/decorator that stores arbitrary properties about a target
Action implementation for use within a specific Action
execution context, for example an ActionState definition, a
TransitionCriteria definition, or in a test environment.
An annotated action is an action that wraps another action (referred to as
the target action), setting up the target action's execution attributes
before invoking
Action.execute .
author: Keith Donald author: Erwin Vervaet |
Constructor Summary | |
public | AnnotatedAction(Action targetAction) Creates a new annotated action object for the specified action. |
Method Summary | |
public Event | execute(RequestContext context) | public String | getMethod() Returns the name of the action method to invoke when the target action is
executed. | public String | getName() Returns the name of a named action, or null if the action
is unnamed. | public Action | getTargetAction() Returns the wrapped target action. | public boolean | isNamed() Returns whether or not the wrapped target action is a named action. | protected Event | postProcessResult(Event resultEvent) Get the event id to be used as grounds for a transition in the containing
state, based on given result returned from action execution.
If the wrapped action is named, the name will be used as a qualifier for
the event (e.g. | public AnnotatedAction | putAttribute(String attributeName, Object attributeValue) Set an attribute on this annotated object. | public void | setMethod(String method) Sets the name of the action method to invoke when the target action is
executed. | public void | setName(String name) Sets the name of a named action. | public void | setTargetAction(Action targetAction) Set the target action wrapped by this decorator. | public String | toString() |
NAME_ATTRIBUTE | final public static String NAME_ATTRIBUTE(Code) | | The action name attribute ("name").
The name attribute is often used as a qualifier for an action's result
event, and is typically used to allow the flow to respond to a specific
action's outcome within a larger action execution chain.
See Also: ActionState |
AnnotatedAction | public AnnotatedAction(Action targetAction)(Code) | | Creates a new annotated action object for the specified action. No
contextual properties are provided.
Parameters: targetAction - the action |
getMethod | public String getMethod()(Code) | | Returns the name of the action method to invoke when the target action is
executed.
|
getTargetAction | public Action getTargetAction()(Code) | | Returns the wrapped target action.
the action |
postProcessResult | protected Event postProcessResult(Event resultEvent)(Code) | | Get the event id to be used as grounds for a transition in the containing
state, based on given result returned from action execution.
If the wrapped action is named, the name will be used as a qualifier for
the event (e.g. "myAction.success").
Parameters: resultEvent - the action result event |
putAttribute | public AnnotatedAction putAttribute(String attributeName, Object attributeValue)(Code) | | Set an attribute on this annotated object.
Parameters: attributeName - the name of the attribute to set Parameters: attributeValue - the value of the attribute this object, to support call chaining since: 1.0.4 |
setMethod | public void setMethod(String method)(Code) | | Sets the name of the action method to invoke when the target action is
executed.
Parameters: method - the action method name |
setName | public void setName(String name)(Code) | | Sets the name of a named action. This is optional and can be
null .
Parameters: name - the action name |
setTargetAction | public void setTargetAction(Action targetAction)(Code) | | Set the target action wrapped by this decorator.
|
|
|