cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r594262 - in /incubator/cxf/trunk: common/common/src/main/java/org/apache/cxf/common/util/ common/common/src/main/java/org/apache/cxf/common/xmlschema/ rt/core/src/main/java/org/apache/cxf/databinding/source/ rt/core/src/main/java/org/apach...
Date Mon, 12 Nov 2007 19:18:24 GMT
Author: dkulp
Date: Mon Nov 12 11:18:23 2007
New Revision: 594262

URL: http://svn.apache.org/viewvc?rev=594262&view=rev
Log:
[CXF-1202] Fix issue with in/out out of band headers
move FixedExtensionDeserializer hack into xmlschema package with the other hacks


Added:
    incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/common/xmlschema/FixedExtensionDeserializer.java
      - copied, changed from r594245, incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/common/util/FixedExtensionDeserializer.java
Removed:
    incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/common/util/FixedExtensionDeserializer.java
Modified:
    incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/common/xmlschema/SchemaCollection.java
    incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/databinding/source/AbstractDataBinding.java
    incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/wsdl11/SchemaUtil.java
    incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/interceptors/HolderOutInterceptor.java

Copied: incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/common/xmlschema/FixedExtensionDeserializer.java
(from r594245, incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/common/util/FixedExtensionDeserializer.java)
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/common/xmlschema/FixedExtensionDeserializer.java?p2=incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/common/xmlschema/FixedExtensionDeserializer.java&p1=incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/common/util/FixedExtensionDeserializer.java&r1=594245&r2=594262&rev=594262&view=diff
==============================================================================
--- incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/common/util/FixedExtensionDeserializer.java
(original)
+++ incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/common/xmlschema/FixedExtensionDeserializer.java
Mon Nov 12 11:18:23 2007
@@ -17,7 +17,7 @@
  * under the License.
  */
 
-package org.apache.cxf.common.util;
+package org.apache.cxf.common.xmlschema;
 
 import java.util.HashMap;
 import java.util.Map;
@@ -39,7 +39,7 @@
  * last one wipes out the earlier recorded extensions.
  */
 @SuppressWarnings("unchecked")
-public class FixedExtensionDeserializer implements ExtensionDeserializer {
+class FixedExtensionDeserializer implements ExtensionDeserializer {
 
     public void deserialize(XmlSchemaObject schemaObject, QName name, Node node) {
 

Modified: incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/common/xmlschema/SchemaCollection.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/common/xmlschema/SchemaCollection.java?rev=594262&r1=594261&r2=594262&view=diff
==============================================================================
--- incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/common/xmlschema/SchemaCollection.java
(original)
+++ incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/common/xmlschema/SchemaCollection.java
Mon Nov 12 11:18:23 2007
@@ -54,6 +54,7 @@
     
     public SchemaCollection(XmlSchemaCollection col) {
         schemaCollection = col;
+        col.getExtReg().setDefaultExtensionDeserializer(new FixedExtensionDeserializer());
     }
 
     public boolean equals(Object obj) {

Modified: incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/databinding/source/AbstractDataBinding.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/databinding/source/AbstractDataBinding.java?rev=594262&r1=594261&r2=594262&view=diff
==============================================================================
--- incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/databinding/source/AbstractDataBinding.java
(original)
+++ incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/databinding/source/AbstractDataBinding.java
Mon Nov 12 11:18:23 2007
@@ -28,7 +28,6 @@
 import org.w3c.dom.Node;
 import org.w3c.dom.NodeList;
 
-import org.apache.cxf.common.util.FixedExtensionDeserializer;
 import org.apache.cxf.common.util.StringUtils;
 import org.apache.cxf.common.xmlschema.SchemaCollection;
 import org.apache.cxf.service.model.SchemaInfo;
@@ -66,7 +65,6 @@
         }
         SchemaInfo schema = new SchemaInfo(serviceInfo, ns);
         schema.setSystemId(systemId);
-        col.getExtReg().setDefaultExtensionDeserializer(new FixedExtensionDeserializer());
         XmlSchema xmlSchema = col.read(d.getDocumentElement());
         schema.setSchema(xmlSchema);
         serviceInfo.addSchema(schema);

Modified: incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/wsdl11/SchemaUtil.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/wsdl11/SchemaUtil.java?rev=594262&r1=594261&r2=594262&view=diff
==============================================================================
--- incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/wsdl11/SchemaUtil.java (original)
+++ incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/wsdl11/SchemaUtil.java Mon Nov
12 11:18:23 2007
@@ -36,7 +36,6 @@
 import org.apache.cxf.Bus;
 import org.apache.cxf.catalog.CatalogXmlSchemaURIResolver;
 import org.apache.cxf.catalog.OASISCatalogManager;
-import org.apache.cxf.common.util.FixedExtensionDeserializer;
 import org.apache.cxf.common.xmlschema.SchemaCollection;
 import org.apache.cxf.helpers.CastUtils;
 import org.apache.cxf.service.model.SchemaInfo;
@@ -58,8 +57,6 @@
 
     public void getSchemas(final Definition def, final ServiceInfo serviceInfo) {
         SchemaCollection schemaCol = serviceInfo.getXmlSchemaCollection();
-        schemaCol.getExtReg().setDefaultExtensionDeserializer(
-            new FixedExtensionDeserializer());
 
         List<Definition> defList = new ArrayList<Definition>();
         parseImports(def, defList);

Modified: incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/interceptors/HolderOutInterceptor.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/interceptors/HolderOutInterceptor.java?rev=594262&r1=594261&r2=594262&view=diff
==============================================================================
--- incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/interceptors/HolderOutInterceptor.java
(original)
+++ incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/interceptors/HolderOutInterceptor.java
Mon Nov 12 11:18:23 2007
@@ -21,6 +21,7 @@
 
 import java.util.ArrayList;
 import java.util.List;
+import java.util.logging.Level;
 import java.util.logging.Logger;
 
 import javax.xml.ws.Holder;
@@ -50,11 +51,13 @@
         Exchange exchange = message.getExchange();
         OperationInfo op = exchange.get(OperationInfo.class);
         
-        LOG.fine("op: " + op);
-        if (null != op) {
-            LOG.fine("op.hasOutput(): " + op.hasOutput());
-            if (op.hasOutput()) {
-                LOG.fine("op.getOutput().size(): " + op.getOutput().size());
+        if (LOG.isLoggable(Level.FINE)) {
+            LOG.fine("op: " + op);
+            if (null != op) {
+                LOG.fine("op.hasOutput(): " + op.hasOutput());
+                if (op.hasOutput()) {
+                    LOG.fine("op.getOutput().size(): " + op.getOutput().size());
+                }
             }
         }
 
@@ -81,21 +84,16 @@
                 }
             }
         } else {
-            List<MessagePartInfo> parts = op.getOutput().getMessageParts();
             List<Object> holders = new ArrayList<Object>(outObjects);
             for (int x = 0; x < outObjects.size(); x++) {
                 Object o = outObjects.get(x);
-                if (!(o instanceof Holder)) {
+                if (o instanceof Holder) {
+                    outObjects.set(x, ((Holder)o).value);
+                } else {
                     holders.set(x, null);
                 }
             }
             message.put(HolderInInterceptor.CLIENT_HOLDERS, holders);
-            for (MessagePartInfo part : parts) {
-                if (part.getIndex() > 0) {
-                    Holder holder = (Holder)outObjects.get(part.getIndex() - 1);
-                    outObjects.set(part.getIndex() - 1, holder.value);
-                }
-            }
         }
         
     }    



Mime
View raw message