diff --git a/spring-webflow/src/main/java/org/springframework/webflow/definition/registry/ExternalizedFlowDefinitionRegistrar.java b/spring-webflow/src/main/java/org/springframework/webflow/definition/registry/ExternalizedFlowDefinitionRegistrar.java index b29d63cb..8397d189 100644 --- a/spring-webflow/src/main/java/org/springframework/webflow/definition/registry/ExternalizedFlowDefinitionRegistrar.java +++ b/spring-webflow/src/main/java/org/springframework/webflow/definition/registry/ExternalizedFlowDefinitionRegistrar.java @@ -57,11 +57,6 @@ public abstract class ExternalizedFlowDefinitionRegistrar implements FlowDefinit */ private Set resources = new HashSet(); - /** - * A set of namespace mappings to load. A set of {@link NamespaceMapping} objects. - */ - private Set namespaceMappings = new HashSet(); - /** * Sets the locations (file paths) pointing to externalized flow definitions. *

@@ -83,16 +78,6 @@ public abstract class ExternalizedFlowDefinitionRegistrar implements FlowDefinit this.resources = new HashSet(Arrays.asList(resources)); } - /** - * Sets the namespace mappings for a set of externalized flow definitions. - *

- * Use this method when you want to add a set of locations or resources in an explicitly named namespace. - * @param namespaceMappings - */ - public void setNamespaceMappings(NamespaceMapping[] namespaceMappings) { - this.namespaceMappings = namespaceMappings; - } - /** * Adds a flow location pointing to an externalized flow resource. *

@@ -143,33 +128,9 @@ public abstract class ExternalizedFlowDefinitionRegistrar implements FlowDefinit return this.resources.addAll(Arrays.asList(resources)); } - /** - * Adds a namespace mapping. - *

- * Use this method when you want to add a set of locations or resources in an explicitly named namespace. - * @param namespaceMappings the namespace mapping - */ - public boolean addNamespaceMapping(NamespaceMapping namespaceMappings) { - return namespaceMappings.add(namespaceMappings); - } - - /** - * Adds namespace mappings. - *

- * Use this method when you want to add a set of locations or resources in an explicitly named namespace. - * @param namespaceMappings the namespace mappings - */ - public boolean addNamespaceMappings(NamespaceMapping[] namespaceMappings) { - if (namespaceMappings == null) { - return false; - } - return this.namespaceMappings.addAll(Arrays.asList(namespaceMappings)); - } - public void registerFlowDefinitions(FlowDefinitionRegistry registry) { processLocations(registry); processResources(registry); - processNamespaces(registry); } // internal helpers @@ -184,39 +145,30 @@ public abstract class ExternalizedFlowDefinitionRegistrar implements FlowDefinit Resource location = (Resource) it.next(); if (isFlowDefinitionResource(location)) { FlowDefinitionResource resource = createFlowDefinitionResource(location); - register(resource, "", registry); + register(resource, registry); } } } /** - * Register the flow definitions at the configured resource locations. + * Register the flow definitions at the configured file locations. * @param registry the registry */ private void processResources(FlowDefinitionRegistry registry) { Iterator it = resources.iterator(); while (it.hasNext()) { FlowDefinitionResource resource = (FlowDefinitionResource) it.next(); - register(resource, "", registry); + register(resource, registry); } } - /** - * Register the flow definitions at the configured resource locations to a given namespace. - * @param registry the registry - */ - private void processNamespaces(FlowDefinitionRegistry registry) { - // TODO - } - /** * Helper method to register the flow built from an externalized resource in the registry. * @param resource representation of the externalized flow definition resource - * @param namespace the namespace to register the flow in * @param registry the flow registry to register the flow in */ - protected final void register(FlowDefinitionResource resource, String namespace, FlowDefinitionRegistry registry) { - registry.registerFlowDefinition(createFlowDefinitionHolder(resource), namespace); + protected final void register(FlowDefinitionResource resource, FlowDefinitionRegistry registry) { + registry.registerFlowDefinition(createFlowDefinitionHolder(resource)); } // subclassing hooks diff --git a/spring-webflow/src/main/java/org/springframework/webflow/engine/builder/xml/XmlFlowRegistrar.java b/spring-webflow/src/main/java/org/springframework/webflow/engine/builder/xml/XmlFlowRegistrar.java index 0c4010e4..ae2994f5 100644 --- a/spring-webflow/src/main/java/org/springframework/webflow/engine/builder/xml/XmlFlowRegistrar.java +++ b/spring-webflow/src/main/java/org/springframework/webflow/engine/builder/xml/XmlFlowRegistrar.java @@ -68,9 +68,8 @@ public class XmlFlowRegistrar extends ExternalizedFlowDefinitionRegistrar { private DocumentLoader documentLoader; /** - * Creates a new XML flow registrar. Protected constructor - if used, make sure the - * {@link #setFlowServiceLocator(FlowServiceLocator)} method is called to set the required flowServiceLocator - * reference. + * Creates a new XML flow registrar. Protected constructor - if used, make sure the required + * {@link #flowServiceLocator} reference is set. */ protected XmlFlowRegistrar() { }