diff --git a/spring-webflow-reference/src/spring-mvc.xml b/spring-webflow-reference/src/spring-mvc.xml index 58284bf5..e2ccfea7 100644 --- a/spring-webflow-reference/src/spring-mvc.xml +++ b/spring-webflow-reference/src/spring-mvc.xml @@ -55,19 +55,30 @@ ]]> For this example both a standard MVC controller and a Web Flow handler are configured. - The controller supports the free navigation aspects of searching and viewing hotels. - The flow handler supports the controlled navigation aspect of booking a hotel room. + The hotelsController supports the free navigation aspects of searching and viewing hotels. + The bookingFlowHandler supports the controlled navigation aspect of booking a hotel room. + + + + Flow Controllers + + Flow controllers provide a basic hook from Spring MVC into Web Flow. + The FlowController class is an implementation of an MVC Controller. + + + + + ]]> + + Web Flow 1.0 used controllers as the only way to hook Web Flow into Spring MVC. + With Web Flow 2.0 flow controllers should be used when the flow is self contained and does not need to interact with the environment. Flow Adapters - The recommended way to bridge Spring MVC requests to Web Flow is via a flow adapter. - - - ]]> - + Flow adapters provide a richer integration point between Spring MVC and Web Flow. The flow adapter provides hooks into the flow execution that can: @@ -83,30 +94,29 @@ handle any exceptions + + + A flow handler should be used whenever integration with any of these hooks is desired. + + The AbstractFlowHandler class is an implementation of FlowHandler that provides default implementations for these hooks. A common pattern to handle a flow outcome is to redirect to a new page instead of rendering a view in the end-state. This allows the URL to be refreshed without throwing an exception. + + ]]> - - Flow Controllers - - Flow controllers provide a direct hook from Spring MVC into Web Flow. - The FlowController class is an implementation of an MVC Controller. - - - Web Flow 1.0 used controllers as the only way to hook Web Flow into Spring MVC. - In Web Flow 2.0 flow handler adapters are recommended instead of controllers as they provide much richer hooks into the web flow engine. - -