|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.springframework.webflow.execution.support.EventFactorySupport
org.springframework.webflow.action.ResultObjectBasedEventFactory
public class ResultObjectBasedEventFactory
Result object-to-event adapter interface that tries to do a sensible conversion of the result object into a web flow event. It uses the following conversion table:
Result object type | Event id | Remarks |
---|---|---|
null | EventFactorySupport.getNullEventId() |
|
Boolean or boolean |
EventFactorySupport.getYesEventId() /
EventFactorySupport.getNoEventId() |
|
LabeledEnum |
LabeledEnum.getLabel() |
The result object will included in the event as an attribute named "result". |
Enum |
Enum.name() |
The result object will included in the event as an attribute named "result". |
String |
The string. | |
Event |
The resulting event object. |
Constructor Summary | |
---|---|
ResultObjectBasedEventFactory()
|
Method Summary | |
---|---|
Event |
createResultEvent(java.lang.Object source,
java.lang.Object resultObject,
RequestContext context)
Create an event instance from the result object. |
boolean |
isMappedValueType(java.lang.Class type)
Check whether or not given type is mapped to a corresponding event using special mapping rules. |
Methods inherited from class org.springframework.webflow.execution.support.EventFactorySupport |
---|
error, error, event, event, event, event, getErrorEventId, getExceptionAttributeName, getNoEventId, getNullEventId, getResultAttributeName, getSuccessEventId, getYesEventId, no, setErrorEventId, setExceptionAttributeName, setNoEventId, setNullEventId, setResultAttributeName, setSuccessEventId, setYesEventId, success, success, yes |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ResultObjectBasedEventFactory()
Method Detail |
---|
public Event createResultEvent(java.lang.Object source, java.lang.Object resultObject, RequestContext context)
ResultEventFactory
createResultEvent
in interface ResultEventFactory
source
- the source of the eventresultObject
- the result object, typically the return value of a bean methodcontext
- a flow execution request context
public boolean isMappedValueType(java.lang.Class type)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |