Action implementation that bundles two or more action execution methods into
a single class. Action execution methods defined by subclasses must adhere to
the following signature:
public Event ${method}(RequestContext context) throws Exception;
When this action is invoked, by default the id of the calling
action state state is treated as the action execution method name.
Alternatively, the execution method name may be explicitly specified as a
property of the calling action state.
For example, the following action state definition:
A typical use of the MultiAction is to centralize all command logic for a
flow in one place. Another common use is to centralize form setup and submit
logic into one place, or CRUD (create/read/update/delete) operations for a
single domain object in one place.
Exposed configuration properties:
Name
Default
Description
methodResolver
Treats the id of the "currentState" as the target method name
Set the strategy used to resolve the name (key) of an action execution
method. Allows full control over the method resolution algorithm.
public Event ${method}(RequestContext context) throws Exception;When this action is invoked, by default theidof the calling action state state is treated as the action execution method name. Alternatively, the execution method name may be explicitly specified as a property of the calling action state.For example, the following action state definition:
<action-state id="search"> <action bean="searchAction"/> <transition on="success" to="results"/> </action-state>... when entered, executes the method:public Event search(RequestContext context) throws Exception;Alternatively you may explictly specify the method name:<action-state id="executingSearch"> <action bean="phonebook" method="executeSearch"/> <transition on="success" to="results"/> </action-state>A typical use of the MultiAction is to centralize all command logic for a flow in one place. Another common use is to centralize form setup and submit logic into one place, or CRUD (create/read/update/delete) operations for a single domain object in one place.
Exposed configuration properties: