Skip to content

Spring Web Flow actions

Extend MultiAction then make sure your signature returns an Event, and accepts a RequestContext as a parameter.

The following example is a very basic action that returns “start” every time.

public class StartAction extends MultiAction {
public Event start(RequestContext context) throws Exception {
Event start = new Event(this, "start");
return start;
}
}

To access to the normal Servlet Request parameters you may be used to use the following code

public Event exampleEvent(RequestContext context) throws Exception {
ExternalContext externalContext = context.getExternalContext();
ParameterMap requestParameterMap = externalContext.getRequestParameterMap();