web-flow.dtd

This DTD defines the web flow XML syntax. Web flows capture the page flow in (part of) a web application.

XML documents that conform to this DTD should declare the following doctype:

<!DOCTYPE web-flow PUBLIC "-//ERVACON//DTD SPRING WEB FLOW//EN" "http://www.ervacon.com/dtd/web-flow.dtd">


DTD source: web-flow.dtd


<web-flow>

Defines the root element for a web flow definition. Web flows are composed of a number of states.

<web-flow>'s children
NameCardinality
action-stateAny number
end-stateAny number
flow-stateAny number
start-stateOnly one
view-stateAny number
<web-flow>'s attributes
NameValuesDefault
name
Element's model :

(start-state,(action-state | view-state | flow-state | end-state)+)


name Attribute of web-flow

Name of the web flow.

Required


<start-state/> Child of web-flow

Defines the start state of the flow. This identifies the state where flow execution will begin.

<start-state>'s attributes
NameValuesDefault
stateIDREF

This tag is always empty.


state Attribute of start-state

Name of the first state of the flow.

Possible values : IDREF - Required


<action-state>

Defines an action state: a state where an action is executed. Transitions triggered by the action(s) lead on to other states.

<action-state>'s children
NameCardinality
actionAt least one
transitionAt least one
<action-state>'s attributes
NameValuesDefault
idID
Element's model :

(action+,transition+)


id Attribute of action-state

Unique id of an action state.

Possible values : ID - Required


<view-state>

Defines a view state: a state where a view will be rendered. Transitions triggered by the view lead on to other states.

<view-state>'s children
NameCardinality
transitionAny number
<view-state>'s attributes
NameValuesDefault
idID
view
Element's model :

(transition*)


id Attribute of view-state

Unique id of a view state.

Possible values : ID - Required


view Attribute of view-state

Name of the view that will be rendered. This is optional. When not present, the response should have been generated elsewhere, e.g. in an action of an action state.


<flow-state>

Defines a flow state: a state where another flow is executed. When the sub flow reaches an end state, the corresponding transition in this state is triggered to continue the flow.

<flow-state>'s children
NameCardinality
transitionAny number
<flow-state>'s attributes
NameValuesDefault
flow
idID
model-mapper
Element's model :

(transition*)


id Attribute of flow-state

Unique id of a flow state.

Possible values : ID - Required


flow Attribute of flow-state

Name of the flow that will be rendered. This is the name of a bean in the application context associated with the flow controller.

Required


model-mapper Attribute of flow-state

Optional name of a mapper that will map model data to and from the sub flow. This is the name of a bean in the application context associated with the flow controller.


<end-state/>

Defines an end state: a state that terminates the flow.

<end-state>'s attributes
NameValuesDefault
idID
view

This tag is always empty.


id Attribute of end-state

Unique id of an end state.

Possible values : ID - Required


view Attribute of end-state

Name of the view that will be rendered. This is optional.


<transition/> Child of action-state,view-state,flow-state

Defines a transition to another state.

<transition>'s attributes
NameValuesDefault
name
toIDREF

This tag is always empty.


name Attribute of transition

Name of the transition. This name is of the form "[actionId'.']event". So the name of the event that will trigger the transition is prepended with the id of the action that signals the event. Both are cancatenated using a dot. So when you have an action with id "myAction" that signals an event "ok", the name of the corresponding transition should be "myAction.ok".

For the events signaled by a view state or a subflow state, no action is involved so the transition name is simply the name of the event that triggers the transition ("ok" in the previous example).

Required


to Attribute of transition

Target state of the transition.

Possible values : IDREF - Required


<action/> Child of action-state

Defines an action that is executed by the flow in an action state.

<action>'s attributes
NameValuesDefault
bean
name

This tag is always empty.


name Attribute of action

Name of the action.

Required


bean Attribute of action

Name of the bean definition of the action in the application context hierarchy linked with the flow. This is similar to the <ref bean="myBean"/> notation of the Spring beans DTD.

Required