diff --git a/spring-webflow-reference/src/actions.xml b/spring-webflow-reference/src/actions.xml
index 019a72cf..b4a96ce6 100644
--- a/spring-webflow-reference/src/actions.xml
+++ b/spring-webflow-reference/src/actions.xml
@@ -1,4 +1,6 @@
+
Executing actions
@@ -348,7 +350,7 @@ public class BookingAction extends MultiAction {
]]>
-
+ Named actions
The following example shows how to execute a chain of actions in an action-state.
diff --git a/spring-webflow-reference/src/defining-flows.xml b/spring-webflow-reference/src/defining-flows.xml
index f2e896f5..641e70f3 100644
--- a/spring-webflow-reference/src/defining-flows.xml
+++ b/spring-webflow-reference/src/defining-flows.xml
@@ -1,4 +1,6 @@
+
Defining Flows
diff --git a/spring-webflow-reference/src/el.xml b/spring-webflow-reference/src/el.xml
index aac5e166..b4daf808 100644
--- a/spring-webflow-reference/src/el.xml
+++ b/spring-webflow-reference/src/el.xml
@@ -1,4 +1,6 @@
+
Expression Language (EL)
@@ -59,8 +61,10 @@
As you can see, explicit delimiters are necessary here to demarcate standard expression blocks within the template.
- See the Web Flow XML schema for a complete listing of those XML attributes that accept standard expressions and those that accept template expressions.
- You can also use F2 in Eclipse (or equivalent shortcut in other IDEs) to access available documentation when typing out specific flow definition attributes.
+
+ See the Web Flow XML schema for a complete listing of those XML attributes that accept standard expressions and those that accept template expressions.
+ You can also use F2 in Eclipse (or equivalent shortcut in other IDEs) to access available documentation when typing out specific flow definition attributes.
+
diff --git a/spring-webflow-reference/src/flow-definition-field-mappings.xml b/spring-webflow-reference/src/flow-definition-field-mappings.xml
index b6ec22cd..e4083f33 100644
--- a/spring-webflow-reference/src/flow-definition-field-mappings.xml
+++ b/spring-webflow-reference/src/flow-definition-field-mappings.xml
@@ -1,4 +1,6 @@
+
Flow Definition Language 1.0 to 2.0 Mappings
diff --git a/spring-webflow-reference/src/flow-inheritance.xml b/spring-webflow-reference/src/flow-inheritance.xml
index 7d469792..3c0a6fd7 100644
--- a/spring-webflow-reference/src/flow-inheritance.xml
+++ b/spring-webflow-reference/src/flow-inheritance.xml
@@ -1,4 +1,6 @@
+
Flow Inheritance
@@ -84,9 +86,11 @@
They will not be modified as part of the merge process.
- Paths to external resources in the parent flow should be absolute.
- Relative paths will break when the two flows are merged unless the parent and child flow are in the same directory.
- Once merged, all relative paths in the parent flow will become relative to the child flow.
+
+ Paths to external resources in the parent flow should be absolute.
+ Relative paths will break when the two flows are merged unless the parent and child flow are in the same directory.
+ Once merged, all relative paths in the parent flow will become relative to the child flow.
+ Mergeable Elements
diff --git a/spring-webflow-reference/src/flow-managed-persistence.xml b/spring-webflow-reference/src/flow-managed-persistence.xml
index 26425a85..c307c9fb 100644
--- a/spring-webflow-reference/src/flow-managed-persistence.xml
+++ b/spring-webflow-reference/src/flow-managed-persistence.xml
@@ -1,4 +1,6 @@
+
Flow Managed Persistence
diff --git a/spring-webflow-reference/src/flow-security.xml b/spring-webflow-reference/src/flow-security.xml
index f41bf14c..8060a3a6 100644
--- a/spring-webflow-reference/src/flow-security.xml
+++ b/spring-webflow-reference/src/flow-security.xml
@@ -1,4 +1,6 @@
+
Securing Flows
diff --git a/spring-webflow-reference/src/overview.xml b/spring-webflow-reference/src/overview.xml
index fb6f0bb4..264ed2ec 100644
--- a/spring-webflow-reference/src/overview.xml
+++ b/spring-webflow-reference/src/overview.xml
@@ -1,21 +1,6 @@
-
- Preface
-
- Many web applications require the same sequence of steps to execute in different contexts.
- Often these sequences are merely components of a larger task the user is trying to accomplish.
- Such a reusable sequence is called a flow.
-
-
- Consider a typical shopping cart application.
- User registration, login, and cart checkout are all examples of flows that can be invoked from several places in this type of application.
-
-
- Spring Web Flow is the module of Spring for implementing flows.
- The Web Flow engine plugs into the Spring Web MVC platform and provides declarative flow definition language.
- This reference guide shows you how to use and extend Spring Web Flow.
-
-
+
Introduction
@@ -332,9 +317,9 @@
Accessing snapshot distribution archives
+
+ Get the snapshot zip with the most recent CI build number from the Web Flow snapshot download area.
+
-
- Get the snapshot zip with the most recent CI build number from the Web Flow snapshot download area.
-
diff --git a/spring-webflow-reference/src/portlet.xml b/spring-webflow-reference/src/portlet.xml
index 74349b82..d50a33f2 100644
--- a/spring-webflow-reference/src/portlet.xml
+++ b/spring-webflow-reference/src/portlet.xml
@@ -1,4 +1,6 @@
+
Portlet Integration
diff --git a/spring-webflow-reference/src/spring-faces.xml b/spring-webflow-reference/src/spring-faces.xml
index 298a0a0c..af88d11a 100644
--- a/spring-webflow-reference/src/spring-faces.xml
+++ b/spring-webflow-reference/src/spring-faces.xml
@@ -1,4 +1,6 @@
+
JSF Integration
@@ -20,22 +22,22 @@
JSF applications using Spring Web Flow applications gain benefits in the following areas:
- Managed bean facility
- Scope management
- Event handling
- Navigation
- Modularization and packaging of views
- Cleaner URLs
- Model-level validation
- Progressivy-enhancement sytle client-side validation
- Progressive-enhancement style Ajax requests with partial page updates
+ Managed bean facility
+ Scope management
+ Event handling
+ Navigation
+ Modularization and packaging of views
+ Cleaner URLs
+ Model-level validation
+ Progressivy-enhancement sytle client-side validation
+ Progressive-enhancement style Ajax requests with partial page updates
Using these features significantly reduce the amount of configuration required in faces-config.xml.
They provide a cleaner separation between the view and controller layers along with better modularization of application functionals.
These features are detailed in the sections to follow.
The majority of these features build on the flow definition language of Spring Web Flow.
- Therefore it is assumed that you have an understanding of the foundations presented in Defining Flows.
+ Therefore it is assumed that you have an understanding of the foundations presented in .
diff --git a/spring-webflow-reference/src/spring-js.xml b/spring-webflow-reference/src/spring-js.xml
index f8a247cc..10edfdf5 100644
--- a/spring-webflow-reference/src/spring-js.xml
+++ b/spring-webflow-reference/src/spring-js.xml
@@ -1,4 +1,6 @@
+
Spring JavaScript Quick Reference
@@ -111,7 +113,7 @@
This decorates the onclick event of the "Previous Results" link with an Ajax call, passing along a special parameter that specifies the fragment to be re-rendered in the response.
Note that this link would still be fully functional if Javascript was unavailable in the client.
- (See the section on Handling Ajax Requests for details on how this request is handled on the server.)
+ (See for details on how this request is handled on the server.)
It is also possible to apply more than one decoration to an element.
diff --git a/spring-webflow-reference/src/spring-mvc.xml b/spring-webflow-reference/src/spring-mvc.xml
index 09bb2d77..4d5980f6 100644
--- a/spring-webflow-reference/src/spring-mvc.xml
+++ b/spring-webflow-reference/src/spring-mvc.xml
@@ -1,4 +1,6 @@
+
Spring MVC Integration
@@ -313,15 +315,15 @@ public class BookingFlowHandler extends AbstractFlowHandler {
Cancel]]>
+
+ Firing an event results in a HTTP request being sent back to the server.
+ On the server-side, the flow handles decoding the event from within its current view-state.
+ How this decoding process works is specific to the view implementation.
+ Recall a Spring MVC view implementation simply looks for a request parameter named _eventId.
+ If no _eventId parameter is found, the view will look for a parameter that
+ starts with _eventId_ and will use the remaining substring as the event id.
+ If neither cases exist, no flow event is triggered.
+
-
- Firing an event results in a HTTP request being sent back to the server.
- On the server-side, the flow handles decoding the event from within its current view-state.
- How this decoding process works is specific to the view implementation.
- Recall a Spring MVC view implementation simply looks for a request parameter named _eventId.
- If no _eventId parameter is found, the view will look for a parameter that
- starts with _eventId_ and will use the remaining substring as the event id.
- If neither cases exist, no flow event is triggered.
-
\ No newline at end of file
diff --git a/spring-webflow-reference/src/spring-webflow-reference.xml b/spring-webflow-reference/src/spring-webflow-reference.xml
index ec72d4e5..b06c9b08 100644
--- a/spring-webflow-reference/src/spring-webflow-reference.xml
+++ b/spring-webflow-reference/src/spring-webflow-reference.xml
@@ -1,26 +1,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-]>
-
+ "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd">
Spring Web Flow Reference Guide
@@ -63,22 +43,40 @@
- &overview;
- &whatsnew;
- &defining-flows;
- ⪙
- &views;
- &actions;
- &flow-managed-persistence;
- &flow-security;
- &flow-inheritance;
- &system-setup;
- &spring-mvc;
- &spring-js;
- &spring-faces;
- &portlet;
- &testing;
- &upgrade-guide;
- &flow-definition-field-mappings;
+
+ Preface
+
+ Many web applications require the same sequence of steps to execute in different contexts.
+ Often these sequences are merely components of a larger task the user is trying to accomplish.
+ Such a reusable sequence is called a flow.
+
+
+ Consider a typical shopping cart application.
+ User registration, login, and cart checkout are all examples of flows that can be invoked from several places in this type of application.
+
+
+ Spring Web Flow is the module of Spring for implementing flows.
+ The Web Flow engine plugs into the Spring Web MVC platform and provides declarative flow definition language.
+ This reference guide shows you how to use and extend Spring Web Flow.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/spring-webflow-reference/src/system-setup.xml b/spring-webflow-reference/src/system-setup.xml
index 73df2067..c1778111 100644
--- a/spring-webflow-reference/src/system-setup.xml
+++ b/spring-webflow-reference/src/system-setup.xml
@@ -1,4 +1,6 @@
+
System Setup
@@ -52,10 +54,10 @@
]]>
+
+ See the Spring MVC and Spring Faces sections of this guide on how to integrate the Web Flow system with the MVC and JSF environment, respectively.
+
-
- See the Spring MVC and Spring Faces sections of this guide on how to integrate the Web Flow system with the MVC and JSF environment, respectively.
- flow-registry options
@@ -200,7 +202,7 @@
Type conversion is used to convert from one type to another when required during flow execution such as when processing request parameters, invoking actions, and so on.
Many common object types such as numbers, classes, and enums are supported.
However you'll probably need to provide your own type conversion and formatting logic for custom data types.
- Please read the Performing Type Conversion section for important information on how to provide custom type conversion logic.
+ Please read for important information on how to provide custom type conversion logic.
@@ -216,11 +218,11 @@
Use the view-factory-creator attribute to customize the ViewFactoryCreator used by the Web Flow system.
The default ViewFactoryCreator produces Spring MVC ViewFactories capable of rendering JSP, Velocity, and Freemarker views.
+
+ The configurable settings are development.
+ These settings are global configuration attributes that can be applied during the flow construction process.
+
-
- The configurable settings are development.
- These settings are global configuration attributes that can be applied during the flow construction process.
- development
diff --git a/spring-webflow-reference/src/testing.xml b/spring-webflow-reference/src/testing.xml
index c20f25d1..eeb6c981 100644
--- a/spring-webflow-reference/src/testing.xml
+++ b/spring-webflow-reference/src/testing.xml
@@ -1,4 +1,6 @@
+
Testing flows
diff --git a/spring-webflow-reference/src/upgrade-guide.xml b/spring-webflow-reference/src/upgrade-guide.xml
index e5e3586e..bfb4e732 100644
--- a/spring-webflow-reference/src/upgrade-guide.xml
+++ b/spring-webflow-reference/src/upgrade-guide.xml
@@ -1,4 +1,6 @@
+
Upgrading from 1.0
@@ -68,7 +70,7 @@ java org.springframework.webflow.upgrade.WebFlowUpgrader flow-to-upgrade.xml
All spring beans can be resolved via EL.
-
+ var scope is no longer supported
The var element will place all variable into flow scope.
@@ -240,7 +242,7 @@ java org.springframework.webflow.upgrade.WebFlowUpgrader flow-to-upgrade.xml
Web Flow 2 adds support for Unified EL.
Web Flow 2.1 uses Spring EL by default.
United EL and OGNL can still be plugged in.
- Please see the Expression Language chapter for details.
+ Please see for details.
@@ -256,7 +258,7 @@ java org.springframework.webflow.upgrade.WebFlowUpgrader flow-to-upgrade.xml
JSF
Web Flow 2 offers significantly improved integration with JSF.
- Please see the JSF Integration chapter for details.
+ Please see for details.
diff --git a/spring-webflow-reference/src/views.xml b/spring-webflow-reference/src/views.xml
index ccdbcb13..ea6a99a8 100644
--- a/spring-webflow-reference/src/views.xml
+++ b/spring-webflow-reference/src/views.xml
@@ -1,4 +1,6 @@
+
Rendering views
@@ -329,8 +331,10 @@ public class ApplicationConversionServiceFactoryBean extends FormattingConversio
Web developers will find the Formatter interface most relevant because it fits the needs of web applications for type conversion.
- An important point to be made is that Object-to-Object conversion is a generalization of the more specific Object-to-String conversion.
- In fact in the end Formatters are reigstered as GenericConverter types with Spring's GenericConversionService making them equal to any other converter.
+
+ An important point to be made is that Object-to-Object conversion is a generalization of the more specific Object-to-String conversion.
+ In fact in the end Formatters are reigstered as GenericConverter types with Spring's GenericConversionService making them equal to any other converter.
+
@@ -454,7 +458,7 @@ public class ApplicationConversionServiceFactoryBean extends FormattingConversio
The second is to implement an external Validator.
Both ways provide you with a ValidationContext to record error messages and access information about the current user.
-
+ Implementing a model validate method
Defining validation logic in your model object is the simplest way to validate its state.
@@ -462,8 +466,7 @@ public class ApplicationConversionServiceFactoryBean extends FormattingConversio
Web Flow conventions have you structure model validation logic by view-state, allowing you to easily validate the subset of model properties that are editable on that view.
To do this, simply create a public method with the name validate${state}, where ${state} is the id of your view-state where you want validation to run.
For example:
-
-
-
+
+
In the example above, when a transition is triggered in a enterBookingDetails view-state that is editing a Booking model,
Web Flow will invoke the validateEnterBookingDetails(ValidationContext) method automatically unless validation has been suppressed for that transition.
An example of such a view-state is shown below:
-
-
]]>
-
+
+
Any number of validation methods are defined. Generally, a flow edits a model over a series of views. In that case, a validate method would be defined
for each view-state where validation needs to run.
-
+ Implementing a Validator
The second way is to define a separate object, called a Validator, which validates your model object.
@@ -534,6 +538,38 @@ public class BookingValidator {
Then, anytime the booking model needs to be validated, this bookingValidator instance would be invoked for you.
+
+ Default validate method
+
+ Within a Validator class, it is also possible to define a method called validate that does not refer to any specific view-state.
+
+
+
+
+ In the upper code sample, the method validate will be called every time a Model of type Booking is being called (unless validation has been suppressed for that transition).
+ If needed, the default method can also be called in addition to an existing state-specific method. Consider the following example:
+
+
+
+
+ In the upper code sample, the method validateEnterBookingDetails will be called first. After that, the default validate method will be called.
+
+ ValidationContext
diff --git a/spring-webflow-reference/src/whatsnew.xml b/spring-webflow-reference/src/whatsnew.xml
index ae40d2d2..f542184b 100644
--- a/spring-webflow-reference/src/whatsnew.xml
+++ b/spring-webflow-reference/src/whatsnew.xml
@@ -1,5 +1,6 @@
-
+
What's New In Spring Web Flow 2.1
@@ -76,7 +77,7 @@
Existing applications can still choose to plug in the Unified EL or OGNL if they wish to do so.
Spring EL however is the recommended approach.
It offers advantages such as close integration with the Spring 3 Type Conversion and Formatting system and is also used in other Spring projects.
- For more information see the Expression Language (EL) chapter.
+ For more information see .
@@ -89,19 +90,17 @@
Existing applications can continue to use the custom converters they currently have.
With the new approach however, they can now use a single mechanism across Spring MVC controllers and flow definitions.
- For more information see the Performing Type Conversion chapter.
+ For more information see .
Tiles Updates
-
Spring Web Flow 2.1 provides support for Tiles 2.1.2.
It has contains important features that can help reduce Tiles related configuration.
This includes wildcard support when listing Tiles definition files or when defining Tiles definitions, anonymous and cascaded nested definitions among others.
See What's new in Tiles 2.1 for more details.
-