Class FlowBuilderContextImpl
java.lang.Object
org.springframework.webflow.engine.builder.support.FlowBuilderContextImpl
- All Implemented Interfaces:
FlowBuilderContext
- Direct Known Subclasses:
MockFlowBuilderContext
Generic implementation of a flow builder context, suitable for use by most flow assembly systems.
- Author:
- Keith Donald
-
Constructor Summary
ConstructorDescriptionFlowBuilderContextImpl
(String flowId, AttributeMap<Object> flowAttributes, FlowDefinitionLocator flowDefinitionLocator, FlowBuilderServices flowBuilderServices) Creates a new flow builder context. -
Method Summary
Modifier and TypeMethodDescriptionprotected ConversionService
Factory method that creates the conversion service the flow builder will use.org.springframework.context.ApplicationContext
Returns the application context hosting the flow system.Returns a generic type conversion service for converting between types, typically from string to a rich value object.Returns the expression parser for parsing expression strings.Returns the factory for core flow artifacts such as Flow and State.Returns externally configured attributes to assign to the flow definition being built.Returns the locator for locating dependent flows (subflows).Returns an externally configured flow definition identifier to assign to the flow being built.Return theValidationHintResolver
.org.springframework.validation.Validator
Returns the Validator instance to use for validating a model.Returns the view factory creator for configuring a ViewFactory per view state
-
Constructor Details
-
FlowBuilderContextImpl
public FlowBuilderContextImpl(String flowId, AttributeMap<Object> flowAttributes, FlowDefinitionLocator flowDefinitionLocator, FlowBuilderServices flowBuilderServices) Creates a new flow builder context.- Parameters:
flowId
- the id to assign the flow being builtflowAttributes
- attributes to assign the flow being builtflowDefinitionLocator
- a locator to find dependent subflowsflowBuilderServices
- a parameter object providing access to additional services needed by the flow builder
-
-
Method Details
-
getFlowBuilderServices
-
getFlowId
Description copied from interface:FlowBuilderContext
Returns an externally configured flow definition identifier to assign to the flow being built.- Specified by:
getFlowId
in interfaceFlowBuilderContext
- Returns:
- the flow id
-
getFlowAttributes
Description copied from interface:FlowBuilderContext
Returns externally configured attributes to assign to the flow definition being built.- Specified by:
getFlowAttributes
in interfaceFlowBuilderContext
- Returns:
- the flow attributes
-
getFlowArtifactFactory
Description copied from interface:FlowBuilderContext
Returns the factory for core flow artifacts such as Flow and State.- Specified by:
getFlowArtifactFactory
in interfaceFlowBuilderContext
- Returns:
- the flow artifact factory
-
getFlowDefinitionLocator
Description copied from interface:FlowBuilderContext
Returns the locator for locating dependent flows (subflows).- Specified by:
getFlowDefinitionLocator
in interfaceFlowBuilderContext
- Returns:
- the flow definition locator
-
getConversionService
Description copied from interface:FlowBuilderContext
Returns a generic type conversion service for converting between types, typically from string to a rich value object.- Specified by:
getConversionService
in interfaceFlowBuilderContext
- Returns:
- the generic conversion service
-
getViewFactoryCreator
Description copied from interface:FlowBuilderContext
Returns the view factory creator for configuring a ViewFactory per view state- Specified by:
getViewFactoryCreator
in interfaceFlowBuilderContext
- Returns:
- the view factory creator
-
getExpressionParser
Description copied from interface:FlowBuilderContext
Returns the expression parser for parsing expression strings.- Specified by:
getExpressionParser
in interfaceFlowBuilderContext
- Returns:
- the expression parser
-
getApplicationContext
public org.springframework.context.ApplicationContext getApplicationContext()Description copied from interface:FlowBuilderContext
Returns the application context hosting the flow system.- Specified by:
getApplicationContext
in interfaceFlowBuilderContext
- Returns:
- the application context
-
getValidator
public org.springframework.validation.Validator getValidator()Description copied from interface:FlowBuilderContext
Returns the Validator instance to use for validating a model.- Specified by:
getValidator
in interfaceFlowBuilderContext
- Returns:
- the validator
-
getValidationHintResolver
Description copied from interface:FlowBuilderContext
Return theValidationHintResolver
.- Specified by:
getValidationHintResolver
in interfaceFlowBuilderContext
-
createConversionService
Factory method that creates the conversion service the flow builder will use. Subclasses may override. The default implementation registers Web Flow-specific converters thought to be useful for most builder implementations, setting the externally-provided builder services conversion service as its parent.- Returns:
- the flow builder conversion service
-