Class FlowModelRegistryImpl
java.lang.Object
org.springframework.webflow.engine.model.registry.FlowModelRegistryImpl
- All Implemented Interfaces:
FlowModelHolderLocator
,FlowModelLocator
,FlowModelRegistry
public class FlowModelRegistryImpl
extends Object
implements FlowModelRegistry, FlowModelHolderLocator
A generic registry implementation for housing one or more flow models.
- Author:
- Keith Donald, Scott Andrews, Rossen Stoyanchev
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiongetFlowModel
(String id) Lookup the flow model with the specified id.Lookup the FlowModelHolder with the specified id.void
registerFlowModel
(String id, FlowModelHolder modelHolder) Register a flow model in this registry.void
setParent
(FlowModelRegistry parent) Sets this registry's parent registry.toString()
-
Constructor Details
-
FlowModelRegistryImpl
public FlowModelRegistryImpl()
-
-
Method Details
-
getFlowModel
Description copied from interface:FlowModelLocator
Lookup the flow model with the specified id.- Specified by:
getFlowModel
in interfaceFlowModelLocator
- Parameters:
id
- the flow model identifier- Returns:
- the flow mode
- Throws:
NoSuchFlowModelException
- when the flow model with the specified id does not exist
-
setParent
Description copied from interface:FlowModelRegistry
Sets this registry's parent registry. When asked by a client to locate a flow model this registry will query it's parent if it cannot fulfill the lookup request itself.- Specified by:
setParent
in interfaceFlowModelRegistry
- Parameters:
parent
- the parent flow model registry, may be null
-
registerFlowModel
Description copied from interface:FlowModelRegistry
Register a flow model in this registry. Registers a "holder", not the Flow model itself. This allows the actual Flow model to be loaded lazily only when needed, and also rebuilt at runtime when its underlying resource changes without re-deploy.- Specified by:
registerFlowModel
in interfaceFlowModelRegistry
- Parameters:
id
- the id to register the flow model undermodelHolder
- a holder holding the flow model to register
-
getFlowModelHolder
Description copied from interface:FlowModelHolderLocator
Lookup the FlowModelHolder with the specified id.- Specified by:
getFlowModelHolder
in interfaceFlowModelHolderLocator
- Parameters:
id
- the flow model identifier- Returns:
- the flow model holder
- Throws:
NoSuchFlowModelException
- when the flow model with the specified id does not exist
-
toString
-