cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From j...@apache.org
Subject svn commit: r597578 - in /incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws: binding/ binding/http/ binding/soap/ support/
Date Fri, 23 Nov 2007 07:29:18 GMT
Author: jliu
Date: Thu Nov 22 23:29:17 2007
New Revision: 597578

URL: http://svn.apache.org/viewvc?rev=597578&view=rev
Log:
Fixed an NPE which is caused by JBI did not implement its Binding type.

Added:
    incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/AbstractBindingImpl.java
      - copied, changed from r597577, incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/BindingImpl.java
    incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/DefaultBindingImpl.java
  (with props)
Removed:
    incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/BindingImpl.java
Modified:
    incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/http/HTTPBindingImpl.java
    incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/soap/SOAPBindingImpl.java
    incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/support/JaxWsEndpointImpl.java

Copied: incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/AbstractBindingImpl.java
(from r597577, incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/BindingImpl.java)
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/AbstractBindingImpl.java?p2=incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/AbstractBindingImpl.java&p1=incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/BindingImpl.java&r1=597577&r2=597578&rev=597578&view=diff
==============================================================================
--- incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/BindingImpl.java
(original)
+++ incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/AbstractBindingImpl.java
Thu Nov 22 23:29:17 2007
@@ -25,7 +25,7 @@
 import javax.xml.ws.Binding;
 import javax.xml.ws.handler.Handler;
 
-public abstract class BindingImpl implements Binding {
+public abstract class AbstractBindingImpl implements Binding {
     private List<Handler> handlerChain = new ArrayList<Handler>();
     
     public List<Handler> getHandlerChain() {

Added: incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/DefaultBindingImpl.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/DefaultBindingImpl.java?rev=597578&view=auto
==============================================================================
--- incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/DefaultBindingImpl.java
(added)
+++ incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/DefaultBindingImpl.java
Thu Nov 22 23:29:17 2007
@@ -0,0 +1,28 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.cxf.jaxws.binding;
+
+public class DefaultBindingImpl extends AbstractBindingImpl {
+    public String getBindingID() {
+        //DefaultBindingImpl should not be used, though JBI binding and
+        //some other bindings did not implement their own Binding.
+        return "";
+    }
+}

Propchange: incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/DefaultBindingImpl.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/DefaultBindingImpl.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Modified: incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/http/HTTPBindingImpl.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/http/HTTPBindingImpl.java?rev=597578&r1=597577&r2=597578&view=diff
==============================================================================
--- incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/http/HTTPBindingImpl.java
(original)
+++ incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/http/HTTPBindingImpl.java
Thu Nov 22 23:29:17 2007
@@ -21,10 +21,10 @@
 
 import javax.xml.ws.http.HTTPBinding;
 
-import org.apache.cxf.jaxws.binding.BindingImpl;
+import org.apache.cxf.jaxws.binding.AbstractBindingImpl;
 import org.apache.cxf.service.model.BindingInfo;
 
-public class HTTPBindingImpl extends BindingImpl implements HTTPBinding {
+public class HTTPBindingImpl extends AbstractBindingImpl implements HTTPBinding {
         
     public HTTPBindingImpl(BindingInfo sb) {       
     }

Modified: incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/soap/SOAPBindingImpl.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/soap/SOAPBindingImpl.java?rev=597578&r1=597577&r2=597578&view=diff
==============================================================================
--- incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/soap/SOAPBindingImpl.java
(original)
+++ incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/binding/soap/SOAPBindingImpl.java
Thu Nov 22 23:29:17 2007
@@ -35,11 +35,11 @@
 import org.apache.cxf.binding.soap.Soap12;
 import org.apache.cxf.binding.soap.model.SoapBindingInfo;
 import org.apache.cxf.common.logging.LogUtils;
-import org.apache.cxf.jaxws.binding.BindingImpl;
+import org.apache.cxf.jaxws.binding.AbstractBindingImpl;
 import org.apache.cxf.message.Message;
 import org.apache.cxf.service.model.BindingInfo;
 
-public class SOAPBindingImpl extends BindingImpl implements SOAPBinding {
+public class SOAPBindingImpl extends AbstractBindingImpl implements SOAPBinding {
     
     private static final Logger LOG = LogUtils.getL7dLogger(SOAPBindingImpl.class);
     private static final ResourceBundle BUNDLE = LOG.getResourceBundle();

Modified: incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/support/JaxWsEndpointImpl.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/support/JaxWsEndpointImpl.java?rev=597578&r1=597577&r2=597578&view=diff
==============================================================================
--- incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/support/JaxWsEndpointImpl.java
(original)
+++ incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/support/JaxWsEndpointImpl.java
Thu Nov 22 23:29:17 2007
@@ -34,6 +34,7 @@
 import org.apache.cxf.endpoint.EndpointImpl;
 import org.apache.cxf.feature.AbstractFeature;
 import org.apache.cxf.interceptor.Interceptor;
+import org.apache.cxf.jaxws.binding.DefaultBindingImpl;
 import org.apache.cxf.jaxws.binding.http.HTTPBindingImpl;
 import org.apache.cxf.jaxws.binding.soap.SOAPBindingImpl;
 import org.apache.cxf.jaxws.handler.logical.DispatchLogicalHandlerInterceptor;
@@ -213,6 +214,11 @@
             }
         } else if (getBinding() instanceof XMLBinding) {
             jaxwsBinding = new HTTPBindingImpl(getEndpointInfo().getBinding());
-        } 
+        } else {
+            //REVISIT: Should not get here, though some bindings like JBI
+            //did not implement their own Binding type.
+            jaxwsBinding = new DefaultBindingImpl();
+           
+        }
     }
 }



Mime
View raw message