camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ningji...@apache.org
Subject svn commit: r1125239 - in /camel/trunk/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/blueprint: CxfNamespaceHandler.java EndpointDefinitionParser.java
Date Fri, 20 May 2011 05:17:26 GMT
Author: ningjiang
Date: Fri May 20 05:17:26 2011
New Revision: 1125239

URL: http://svn.apache.org/viewvc?rev=1125239&view=rev
Log:
Clean up the cxf blueprint parser, removed the useless codes

Modified:
    camel/trunk/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/blueprint/CxfNamespaceHandler.java
    camel/trunk/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/blueprint/EndpointDefinitionParser.java

Modified: camel/trunk/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/blueprint/CxfNamespaceHandler.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/blueprint/CxfNamespaceHandler.java?rev=1125239&r1=1125238&r2=1125239&view=diff
==============================================================================
--- camel/trunk/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/blueprint/CxfNamespaceHandler.java
(original)
+++ camel/trunk/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/blueprint/CxfNamespaceHandler.java
Fri May 20 05:17:26 2011
@@ -36,6 +36,7 @@ public class CxfNamespaceHandler impleme
         return getClass().getClassLoader().getResource("schema/blueprint/camel-cxf.xsd");
     }
 
+    @SuppressWarnings("unchecked")
     public Set<Class> getManagedClasses() {
         return new HashSet<Class>(Arrays.asList(CxfNamespaceHandler.class));
     }

Modified: camel/trunk/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/blueprint/EndpointDefinitionParser.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/blueprint/EndpointDefinitionParser.java?rev=1125239&r1=1125238&r2=1125239&view=diff
==============================================================================
--- camel/trunk/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/blueprint/EndpointDefinitionParser.java
(original)
+++ camel/trunk/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/blueprint/EndpointDefinitionParser.java
Fri May 20 05:17:26 2011
@@ -70,13 +70,10 @@ public class EndpointDefinitionParser ex
         } else {
             endpointConfig.setId("camel.cxf.endpoint." + context.generateId());
         }
-
-        boolean isAbstract = false;
-        boolean publish = true;
+      
         NamedNodeMap atts = element.getAttributes();
 
         String bus = null;
-        Metadata impl = null;
         String address = null;
 
         for (int i = 0; i < atts.getLength(); i++) {
@@ -84,12 +81,7 @@ public class EndpointDefinitionParser ex
             String val = node.getValue();
             String pre = node.getPrefix();
             String name = node.getLocalName();
-            if ("createdFromAPI".equals(name) || "abstract".equals(name)) {
-                endpointConfig.setScope(MutableBeanMetadata.SCOPE_PROTOTYPE);
-                isAbstract = true;
-            } else if ("publish".equals(name)) {
-                publish = Boolean.parseBoolean(val);
-            } else if ("bus".equals(name)) {
+            if ("bus".equals(name)) {
                 bus = val;
             } else if ("address".equals(name)) {
                 address = val;
@@ -99,12 +91,6 @@ public class EndpointDefinitionParser ex
                     endpointConfig.addProperty(name, createValue(context, q));
                 } else if ("depends-on".equals(name)) {
                     endpointConfig.addDependsOn(val);
-                } else if ("implementor".equals(name)) {
-                    if (val.startsWith("#")) {
-                        impl = createRef(context, val.substring(1));
-                    } else {
-                        impl = createObjectOfClass(context, val);
-                    }
                 } else if (!"name".equals(name)) {
                     endpointConfig.addProperty(name, AbstractBPBeanDefinitionParser.createValue(context,
val));
                 }
@@ -194,6 +180,7 @@ public class EndpointDefinitionParser ex
             this.blueprintContainer = blueprintContainer;
         }
 
+        @SuppressWarnings("unchecked")
         public void process(ComponentDefinitionRegistry componentDefinitionRegistry) {
             MutableBeanMetadata bean = (MutableBeanMetadata) blueprintContainer.getComponentMetadata(cxfEndpointName);
 



Mime
View raw message