|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.springframework.webflow.engine.support.TransitionExecutingFlowExecutionExceptionHandler
public class TransitionExecutingFlowExecutionExceptionHandler
A flow execution exception handler that maps the occurrence of a specific type of exception to a transition to a new
State
.
The handled FlowExecutionException
will be exposed in flash scope as
FLOW_EXECUTION_EXCEPTION_ATTRIBUTE
. The underlying root cause of that exception will be exposed in flash
scope as ROOT_CAUSE_EXCEPTION_ATTRIBUTE
.
Field Summary | |
---|---|
static String |
FLOW_EXECUTION_EXCEPTION_ATTRIBUTE
The name of the attribute to expose a handled exception under in flash scope ("flowExecutionException"). |
static String |
ROOT_CAUSE_EXCEPTION_ATTRIBUTE
The name of the attribute to expose a root cause of a handled exception under in flash scope ("rootCauseException"). |
Constructor Summary | |
---|---|
TransitionExecutingFlowExecutionExceptionHandler()
|
Method Summary | |
---|---|
TransitionExecutingFlowExecutionExceptionHandler |
add(Class exceptionClass,
String targetStateId)
Adds an exception-to-target state mapping to this handler. |
TransitionExecutingFlowExecutionExceptionHandler |
add(Class exceptionClass,
TargetStateResolver targetStateResolver)
Adds a exception-to-target state resolver mapping to this handler. |
boolean |
canHandle(FlowExecutionException e)
Can this handler handle the given exception? |
ActionList |
getActionList()
Returns the list of actions to execute when this handler handles an exception. |
void |
handle(FlowExecutionException exception,
RequestControlContext context)
Handle the exception in the context of the current request. |
String |
toString()
|
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final String FLOW_EXECUTION_EXCEPTION_ATTRIBUTE
public static final String ROOT_CAUSE_EXCEPTION_ATTRIBUTE
Constructor Detail |
---|
public TransitionExecutingFlowExecutionExceptionHandler()
Method Detail |
---|
public TransitionExecutingFlowExecutionExceptionHandler add(Class exceptionClass, String targetStateId)
exceptionClass
- the type of exception to maptargetStateId
- the id of the state to transition to if the specified type of exception is handled
public TransitionExecutingFlowExecutionExceptionHandler add(Class exceptionClass, TargetStateResolver targetStateResolver)
exceptionClass
- the type of exception to maptargetStateResolver
- the resolver to calculate the state to transition to if the specified type of
exception is handled
public ActionList getActionList()
public boolean canHandle(FlowExecutionException e)
FlowExecutionExceptionHandler
canHandle
in interface FlowExecutionExceptionHandler
e
- the exception that occurred
public void handle(FlowExecutionException exception, RequestControlContext context)
FlowExecutionExceptionHandler
RequestControlContext.execute(Transition)
.
handle
in interface FlowExecutionExceptionHandler
exception
- the exception that occurredcontext
- the execution control context for this requestpublic String toString()
toString
in class Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |