diff options
6 files changed, 91 insertions, 5 deletions
diff --git a/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/BaseAssemblyProcessor.java b/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/BaseAssemblyProcessor.java index ebe85da4be..edcbd13465 100644 --- a/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/BaseAssemblyProcessor.java +++ b/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/BaseAssemblyProcessor.java @@ -21,6 +21,18 @@ package org.apache.tuscany.sca.assembly.xml; import static javax.xml.XMLConstants.W3C_XML_SCHEMA_INSTANCE_NS_URI; import static javax.xml.XMLConstants.XMLNS_ATTRIBUTE_NS_URI; +import static org.apache.tuscany.sca.assembly.xml.Constants.ELEMENT; +import static org.apache.tuscany.sca.assembly.xml.Constants.MANY; +import static org.apache.tuscany.sca.assembly.xml.Constants.MULTIPLICITY; +import static org.apache.tuscany.sca.assembly.xml.Constants.MUST_SUPPLY; +import static org.apache.tuscany.sca.assembly.xml.Constants.NAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.ONE_N; +import static org.apache.tuscany.sca.assembly.xml.Constants.ONE_ONE; +import static org.apache.tuscany.sca.assembly.xml.Constants.SCA10_NS; +import static org.apache.tuscany.sca.assembly.xml.Constants.TARGET; +import static org.apache.tuscany.sca.assembly.xml.Constants.TYPE; +import static org.apache.tuscany.sca.assembly.xml.Constants.ZERO_N; +import static org.apache.tuscany.sca.assembly.xml.Constants.ZERO_ONE; import java.util.ArrayList; import java.util.List; @@ -86,7 +98,7 @@ import org.w3c.dom.NodeList; * * @version $Rev$ $Date$ */ -abstract class BaseAssemblyProcessor extends BaseStAXArtifactProcessor implements Constants { +abstract class BaseAssemblyProcessor extends BaseStAXArtifactProcessor { protected AssemblyFactory assemblyFactory; protected PolicyFactory policyFactory; diff --git a/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/ComponentTypeProcessor.java b/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/ComponentTypeProcessor.java index 695d133940..5b5f15cb96 100644 --- a/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/ComponentTypeProcessor.java +++ b/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/ComponentTypeProcessor.java @@ -21,6 +21,23 @@ package org.apache.tuscany.sca.assembly.xml; import static javax.xml.stream.XMLStreamConstants.END_ELEMENT; import static javax.xml.stream.XMLStreamConstants.START_ELEMENT; +import static org.apache.tuscany.sca.assembly.xml.Constants.CALLBACK; +import static org.apache.tuscany.sca.assembly.xml.Constants.CALLBACK_QNAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.COMPONENT_TYPE; +import static org.apache.tuscany.sca.assembly.xml.Constants.COMPONENT_TYPE_QNAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.ELEMENT; +import static org.apache.tuscany.sca.assembly.xml.Constants.IMPLEMENTATION; +import static org.apache.tuscany.sca.assembly.xml.Constants.MANY; +import static org.apache.tuscany.sca.assembly.xml.Constants.MUST_SUPPLY; +import static org.apache.tuscany.sca.assembly.xml.Constants.NAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.OPERATION_QNAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.PROPERTY; +import static org.apache.tuscany.sca.assembly.xml.Constants.PROPERTY_QNAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.REFERENCE; +import static org.apache.tuscany.sca.assembly.xml.Constants.REFERENCE_QNAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.SERVICE; +import static org.apache.tuscany.sca.assembly.xml.Constants.SERVICE_QNAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.TYPE; import javax.xml.namespace.QName; import javax.xml.stream.XMLStreamException; diff --git a/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/CompositeProcessor.java b/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/CompositeProcessor.java index 16ba2f81b5..f6db3fe94c 100644 --- a/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/CompositeProcessor.java +++ b/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/CompositeProcessor.java @@ -21,6 +21,40 @@ package org.apache.tuscany.sca.assembly.xml; import static javax.xml.stream.XMLStreamConstants.END_ELEMENT; import static javax.xml.stream.XMLStreamConstants.START_ELEMENT; +import static org.apache.tuscany.sca.assembly.xml.Constants.AUTOWIRE; +import static org.apache.tuscany.sca.assembly.xml.Constants.CALLBACK; +import static org.apache.tuscany.sca.assembly.xml.Constants.CALLBACK_QNAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.COMPONENT; +import static org.apache.tuscany.sca.assembly.xml.Constants.COMPONENT_QNAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.COMPOSITE; +import static org.apache.tuscany.sca.assembly.xml.Constants.COMPOSITE_QNAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.ELEMENT; +import static org.apache.tuscany.sca.assembly.xml.Constants.FILE; +import static org.apache.tuscany.sca.assembly.xml.Constants.IMPLEMENTATION_COMPOSITE; +import static org.apache.tuscany.sca.assembly.xml.Constants.IMPLEMENTATION_COMPOSITE_QNAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.INCLUDE; +import static org.apache.tuscany.sca.assembly.xml.Constants.INCLUDE_QNAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.LOCAL; +import static org.apache.tuscany.sca.assembly.xml.Constants.MANY; +import static org.apache.tuscany.sca.assembly.xml.Constants.MUST_SUPPLY; +import static org.apache.tuscany.sca.assembly.xml.Constants.NAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.OPERATION_QNAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.PROMOTE; +import static org.apache.tuscany.sca.assembly.xml.Constants.PROPERTY; +import static org.apache.tuscany.sca.assembly.xml.Constants.PROPERTY_QNAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.REFERENCE; +import static org.apache.tuscany.sca.assembly.xml.Constants.REFERENCE_QNAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.SCA10_NS; +import static org.apache.tuscany.sca.assembly.xml.Constants.SERVICE; +import static org.apache.tuscany.sca.assembly.xml.Constants.SERVICE_QNAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.SOURCE; +import static org.apache.tuscany.sca.assembly.xml.Constants.TARGET; +import static org.apache.tuscany.sca.assembly.xml.Constants.TARGET_NAMESPACE; +import static org.apache.tuscany.sca.assembly.xml.Constants.TYPE; +import static org.apache.tuscany.sca.assembly.xml.Constants.URI; +import static org.apache.tuscany.sca.assembly.xml.Constants.WIRE; +import static org.apache.tuscany.sca.assembly.xml.Constants.WIRED_BY_IMPL; +import static org.apache.tuscany.sca.assembly.xml.Constants.WIRE_QNAME; import java.util.ArrayList; import java.util.Iterator; diff --git a/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/ConfiguredOperationProcessor.java b/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/ConfiguredOperationProcessor.java index 5d9eccebde..aed535cf0d 100644 --- a/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/ConfiguredOperationProcessor.java +++ b/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/ConfiguredOperationProcessor.java @@ -18,8 +18,11 @@ */ package org.apache.tuscany.sca.assembly.xml; - import static javax.xml.stream.XMLStreamConstants.END_ELEMENT; +import static org.apache.tuscany.sca.assembly.xml.Constants.NAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.OPERATION; +import static org.apache.tuscany.sca.assembly.xml.Constants.OPERATION_QNAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.SERVICE; import javax.xml.namespace.QName; import javax.xml.stream.XMLStreamException; @@ -34,15 +37,15 @@ import org.apache.tuscany.sca.contribution.processor.ContributionWriteException; import org.apache.tuscany.sca.contribution.processor.StAXArtifactProcessor; import org.apache.tuscany.sca.contribution.resolver.ModelResolver; import org.apache.tuscany.sca.core.FactoryExtensionPoint; -import org.apache.tuscany.sca.policy.PolicyFactory; import org.apache.tuscany.sca.monitor.Monitor; +import org.apache.tuscany.sca.policy.PolicyFactory; /** * Processor for dealing with 'operation' elements from composite definitions * * @version $Rev$ $Date$ */ -public class ConfiguredOperationProcessor implements StAXArtifactProcessor<ConfiguredOperation>, Constants{ +public class ConfiguredOperationProcessor implements StAXArtifactProcessor<ConfiguredOperation> { private AssemblyFactory assemblyFactory; private PolicyAttachPointProcessor policyProcessor; diff --git a/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/ConstrainingTypeProcessor.java b/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/ConstrainingTypeProcessor.java index 1031791c32..8b187960c5 100644 --- a/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/ConstrainingTypeProcessor.java +++ b/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/ConstrainingTypeProcessor.java @@ -21,6 +21,21 @@ package org.apache.tuscany.sca.assembly.xml; import static javax.xml.stream.XMLStreamConstants.END_ELEMENT; import static javax.xml.stream.XMLStreamConstants.START_ELEMENT; +import static org.apache.tuscany.sca.assembly.xml.Constants.CONSTRAINING_TYPE; +import static org.apache.tuscany.sca.assembly.xml.Constants.CONSTRAINING_TYPE_QNAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.ELEMENT; +import static org.apache.tuscany.sca.assembly.xml.Constants.MANY; +import static org.apache.tuscany.sca.assembly.xml.Constants.MUST_SUPPLY; +import static org.apache.tuscany.sca.assembly.xml.Constants.NAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.OPERATION_QNAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.PROPERTY; +import static org.apache.tuscany.sca.assembly.xml.Constants.PROPERTY_QNAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.REFERENCE; +import static org.apache.tuscany.sca.assembly.xml.Constants.REFERENCE_QNAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.SERVICE; +import static org.apache.tuscany.sca.assembly.xml.Constants.SERVICE_QNAME; +import static org.apache.tuscany.sca.assembly.xml.Constants.TARGET_NAMESPACE; +import static org.apache.tuscany.sca.assembly.xml.Constants.TYPE; import javax.xml.namespace.QName; import javax.xml.stream.XMLStreamException; diff --git a/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/PolicyAttachPointProcessor.java b/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/PolicyAttachPointProcessor.java index fc4e10654d..359f87c615 100644 --- a/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/PolicyAttachPointProcessor.java +++ b/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/PolicyAttachPointProcessor.java @@ -19,6 +19,11 @@ package org.apache.tuscany.sca.assembly.xml; +import static org.apache.tuscany.sca.assembly.xml.Constants.APPLICABLE_POLICY_SETS; +import static org.apache.tuscany.sca.assembly.xml.Constants.POLICY_SETS; +import static org.apache.tuscany.sca.assembly.xml.Constants.REQUIRES; +import static org.apache.tuscany.sca.assembly.xml.Constants.SCA10_TUSCANY_NS; + import java.util.ArrayList; import java.util.List; import java.util.StringTokenizer; @@ -42,7 +47,7 @@ import org.apache.tuscany.sca.policy.PolicySetAttachPoint; * * @version $Rev$ $Date$ */ -public class PolicyAttachPointProcessor extends BaseStAXArtifactProcessor implements Constants { +public class PolicyAttachPointProcessor extends BaseStAXArtifactProcessor { private PolicyFactory policyFactory; |