Class BeanFactoryVariableValueFactory
java.lang.Object
org.springframework.webflow.engine.support.BeanFactoryVariableValueFactory
- All Implemented Interfaces:
VariableValueFactory
A bean-factory backed variable value factory. Relies on an autowire-capable bean factory to wire variable value
dependencies on value creation and restoration.
- Author:
- Keith Donald
-
Constructor Summary
ConstructorsConstructorDescriptionBeanFactoryVariableValueFactory
(Class<?> type, org.springframework.beans.factory.config.AutowireCapableBeanFactory beanFactory) Creates a new bean factory variable factory. -
Method Summary
Modifier and TypeMethodDescriptioncreateInitialValue
(RequestContext context) Creates the variable's initial value.void
restoreReferences
(Object value, RequestContext context) Restore any references the variable's value needs to other objects.toString()
-
Constructor Details
-
BeanFactoryVariableValueFactory
public BeanFactoryVariableValueFactory(Class<?> type, org.springframework.beans.factory.config.AutowireCapableBeanFactory beanFactory) Creates a new bean factory variable factory.- Parameters:
type
- the variable classbeanFactory
- the bean factory that will create and restore variable instances.
-
-
Method Details
-
createInitialValue
Description copied from interface:VariableValueFactory
Creates the variable's initial value.- Specified by:
createInitialValue
in interfaceVariableValueFactory
- Parameters:
context
- the currently executing flow request- Returns:
- the value
-
restoreReferences
Description copied from interface:VariableValueFactory
Restore any references the variable's value needs to other objects. Such references may have been lost during deserialization, for example, and need to be restored.- Specified by:
restoreReferences
in interfaceVariableValueFactory
- Parameters:
value
- the current variable valuecontext
- the currently executing flow request
-
toString
-