Default implementation of FlowExecution that uses a stack-based data
structure to manage spawned flow sessions. This class is closely coupled with
package-private FlowSessionImpl and
RequestControlContextImpl. The three classes work together to
form a complete flow execution implementation based on a finite state
machine.
This implementation of FlowExecution is serializable so it can be safely
stored in an HTTP session or other persistent store such as a file, database,
or client-side form field. Once deserialized, the
FlowExecutionImplStateRestorer strategy is expected to be used to
restore the execution to a usable state.
See Also:FlowExecutionImplFactory See Also:FlowExecutionImplStateRestorer author: Keith Donald author: Erwin Vervaet author: Ben Hale
Constructor Summary
public
FlowExecutionImpl() Default constructor required for externalizable serialization.
public
FlowExecutionImpl(Flow flow) Create a new flow execution executing the provided flow.
Create a new flow execution executing the provided flow. This constructor
is mainly used for testing.
Parameters: flow - the root flow of this flow execution
Create a new flow execution executing the provided flow.
Parameters: flow - the root flow of this flow execution Parameters: listeners - the listeners interested in flow execution lifecycleevents Parameters: attributes - flow execution system attributes
Activate a new FlowSession for the flow definition.
Creates the new flow session and pushes it onto the stack.
Parameters: flow - the flow definition the new flow session
Create a new flow session object. Subclasses can override this to return
a special implementation if required.
Parameters: flow - the flow that should be associated with the flow session Parameters: parent - the flow session that should be the parent of the newlycreated flow session (may be null) the newly created flow session
Handles an exception that occured performing an operation on this flow
execution. First trys the set of exception handlers associated with the
offending state, then the handlers at the flow level.
Parameters: exception - the exception that occured Parameters: context - the request control context the exception occured in the selected error view, never null throws: FlowExecutionException - rethrows the exception if it was not handledat the state or flow level
Pause this flow execution.
Parameters: context - the request control context Parameters: selectedView - the initial selected view to render the selected view to render