You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by dk...@apache.org on 2008/08/11 19:21:38 UTC

svn commit: r684825 - in /cxf/branches/2.0.x-fixes: ./ api/src/main/java/org/apache/cxf/configuration/jsse/ rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/ rt/core/src/main/java/org/apache/cxf/binding/ rt/core/src/main/java/org/apache/cxf/b...

Author: dkulp
Date: Mon Aug 11 10:21:27 2008
New Revision: 684825

URL: http://svn.apache.org/viewvc?rev=684825&view=rev
Log:
Merged revisions 684790-684791,684793 via svnmerge from 
https://svn.apache.org/repos/asf/cxf/trunk

........
  r684790 | dkulp | 2008-08-11 12:06:09 -0400 (Mon, 11 Aug 2008) | 5 lines
  
  [CXF-1740,CXF-1721] Fix the generated code if style="rpc" is on the operations and not the whole binding
  Also update a bunch of @Resource things to work correctly (or remove them if not needed)
  Remove gc() from javascript test.  It now seems to be ok.
  Fix separator for urn in WS-Addressing stuff
........
  r684791 | dkulp | 2008-08-11 12:13:00 -0400 (Mon, 11 Aug 2008) | 2 lines
  
  Fix Typo
........
  r684793 | dkulp | 2008-08-11 12:19:04 -0400 (Mon, 11 Aug 2008) | 2 lines
  
  Better "assert" line
........

Modified:
    cxf/branches/2.0.x-fixes/   (props changed)
    cxf/branches/2.0.x-fixes/api/src/main/java/org/apache/cxf/configuration/jsse/TLSServerParameters.java
    cxf/branches/2.0.x-fixes/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/SoapTransportFactory.java
    cxf/branches/2.0.x-fixes/rt/core/src/main/java/org/apache/cxf/binding/AbstractBindingFactory.java
    cxf/branches/2.0.x-fixes/rt/core/src/main/java/org/apache/cxf/bus/extension/ExtensionManagerBus.java
    cxf/branches/2.0.x-fixes/rt/management/src/main/java/org/apache/cxf/management/counters/CounterRepository.java
    cxf/branches/2.0.x-fixes/rt/management/src/main/java/org/apache/cxf/management/jmx/InstrumentationManagerImpl.java
    cxf/branches/2.0.x-fixes/rt/transports/http-jetty/src/main/java/org/apache/cxf/transport/http_jetty/JettyHTTPServerEngine.java
    cxf/branches/2.0.x-fixes/rt/transports/http-jetty/src/main/java/org/apache/cxf/transport/http_jetty/JettyHTTPServerEngineFactory.java
    cxf/branches/2.0.x-fixes/rt/transports/http-jetty/src/main/java/org/apache/cxf/transport/http_jetty/JettyHTTPTransportFactory.java
    cxf/branches/2.0.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/http/AbstractHTTPTransportFactory.java
    cxf/branches/2.0.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletTransportFactory.java
    cxf/branches/2.0.x-fixes/rt/transports/jbi/src/main/java/org/apache/cxf/transport/jbi/JBITransportFactory.java
    cxf/branches/2.0.x-fixes/rt/transports/jms/src/main/java/org/apache/cxf/transport/jms/JMSTransportFactory.java
    cxf/branches/2.0.x-fixes/rt/transports/local/src/main/java/org/apache/cxf/transport/local/LocalTransportFactory.java
    cxf/branches/2.0.x-fixes/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/MAPAggregator.java
    cxf/branches/2.0.x-fixes/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/OperationProcessor.java
    cxf/branches/2.0.x-fixes/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/annotator/BindingAnnotator.java
    cxf/branches/2.0.x-fixes/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/annotator/SoapBindingAnnotator.java
    cxf/branches/2.0.x-fixes/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenBugTest.java
    cxf/branches/2.0.x-fixes/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java
    cxf/branches/2.0.x-fixes/tools/wsdlto/test/src/test/resources/wsdl2java_wsdl/bug978/bug.wsdl

Propchange: cxf/branches/2.0.x-fixes/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Mon Aug 11 10:21:27 2008
@@ -1 +1 @@
-/cxf/trunk:673548,674485,674547,674551,674562,674601,674649,674764,674887,675644,675653,677048,677385,678004,678009,678559,678629,678808,678852,678891,678893,679248,679597,680435,681060,681165,681813,681816,682902,682951,683089,683290,683318,684099
+/cxf/trunk:673548,674485,674547,674551,674562,674601,674649,674764,674887,675644,675653,677048,677385,678004,678009,678559,678629,678808,678852,678891,678893,679248,679597,680435,681060,681165,681813,681816,682902,682951,683089,683290,683318,684099,684790-684793

Propchange: cxf/branches/2.0.x-fixes/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Mon Aug 11 10:21:27 2008
@@ -1 +1 @@
-/cxf/trunk:1-684687
+/cxf/trunk:1-684818

Modified: cxf/branches/2.0.x-fixes/api/src/main/java/org/apache/cxf/configuration/jsse/TLSServerParameters.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.0.x-fixes/api/src/main/java/org/apache/cxf/configuration/jsse/TLSServerParameters.java?rev=684825&r1=684824&r2=684825&view=diff
==============================================================================
--- cxf/branches/2.0.x-fixes/api/src/main/java/org/apache/cxf/configuration/jsse/TLSServerParameters.java (original)
+++ cxf/branches/2.0.x-fixes/api/src/main/java/org/apache/cxf/configuration/jsse/TLSServerParameters.java Mon Aug 11 10:21:27 2008
@@ -18,8 +18,6 @@
  */
 package org.apache.cxf.configuration.jsse;
 
-import javax.annotation.Resource;
-
 import org.apache.cxf.configuration.security.ClientAuthentication;
 
 /**
@@ -35,7 +33,6 @@
      * This parameter configures the server side to request and/or
      * require client authentication.
      */
-    @Resource
     public final void setClientAuthentication(ClientAuthentication clientAuth) {
         clientAuthentication = clientAuth;
     }

Modified: cxf/branches/2.0.x-fixes/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/SoapTransportFactory.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.0.x-fixes/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/SoapTransportFactory.java?rev=684825&r1=684824&r2=684825&view=diff
==============================================================================
--- cxf/branches/2.0.x-fixes/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/SoapTransportFactory.java (original)
+++ cxf/branches/2.0.x-fixes/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/SoapTransportFactory.java Mon Aug 11 10:21:27 2008
@@ -154,7 +154,7 @@
         return bus;
     }
 
-    @Resource(name = "bus")
+    @Resource(name = "cxf")
     public void setBus(Bus bus) {
         this.bus = bus;
     }

Modified: cxf/branches/2.0.x-fixes/rt/core/src/main/java/org/apache/cxf/binding/AbstractBindingFactory.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.0.x-fixes/rt/core/src/main/java/org/apache/cxf/binding/AbstractBindingFactory.java?rev=684825&r1=684824&r2=684825&view=diff
==============================================================================
--- cxf/branches/2.0.x-fixes/rt/core/src/main/java/org/apache/cxf/binding/AbstractBindingFactory.java (original)
+++ cxf/branches/2.0.x-fixes/rt/core/src/main/java/org/apache/cxf/binding/AbstractBindingFactory.java Mon Aug 11 10:21:27 2008
@@ -170,7 +170,7 @@
         return bus;
     }
 
-    @Resource(name = "bus")
+    @Resource
     public void setBus(Bus bus) {
         this.bus = bus;
     }

Modified: cxf/branches/2.0.x-fixes/rt/core/src/main/java/org/apache/cxf/bus/extension/ExtensionManagerBus.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.0.x-fixes/rt/core/src/main/java/org/apache/cxf/bus/extension/ExtensionManagerBus.java?rev=684825&r1=684824&r2=684825&view=diff
==============================================================================
--- cxf/branches/2.0.x-fixes/rt/core/src/main/java/org/apache/cxf/bus/extension/ExtensionManagerBus.java (original)
+++ cxf/branches/2.0.x-fixes/rt/core/src/main/java/org/apache/cxf/bus/extension/ExtensionManagerBus.java Mon Aug 11 10:21:27 2008
@@ -73,6 +73,7 @@
         
         properties.put(BUS_ID_PROPERTY_NAME, BUS_PROPERTY_NAME);
         properties.put(BUS_PROPERTY_NAME, this);
+        properties.put(DEFAULT_BUS_ID, this);
         
         ResourceResolver propertiesResolver = new PropertiesResolver(properties);
         resourceManager.addResourceResolver(propertiesResolver);
@@ -81,6 +82,10 @@
         resourceManager.addResourceResolver(busResolver);
         resourceManager.addResourceResolver(new ObjectTypeResolver(this));
         
+        busResolver = new SinglePropertyResolver(DEFAULT_BUS_ID, this);
+        resourceManager.addResourceResolver(busResolver);
+        resourceManager.addResourceResolver(new ObjectTypeResolver(this));
+        
         extensions.put(ResourceManager.class, resourceManager);
 
         ExtensionManagerImpl em = new ExtensionManagerImpl(

Modified: cxf/branches/2.0.x-fixes/rt/management/src/main/java/org/apache/cxf/management/counters/CounterRepository.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.0.x-fixes/rt/management/src/main/java/org/apache/cxf/management/counters/CounterRepository.java?rev=684825&r1=684824&r2=684825&view=diff
==============================================================================
--- cxf/branches/2.0.x-fixes/rt/management/src/main/java/org/apache/cxf/management/counters/CounterRepository.java (original)
+++ cxf/branches/2.0.x-fixes/rt/management/src/main/java/org/apache/cxf/management/counters/CounterRepository.java Mon Aug 11 10:21:27 2008
@@ -53,7 +53,7 @@
         counters = new ConcurrentHashMap<ObjectName, Counter>();
     }
     
-    @Resource(name = "bus")
+    @Resource(name = "cxf")
     public void setBus(Bus b) {
         bus = b;
     }

Modified: cxf/branches/2.0.x-fixes/rt/management/src/main/java/org/apache/cxf/management/jmx/InstrumentationManagerImpl.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.0.x-fixes/rt/management/src/main/java/org/apache/cxf/management/jmx/InstrumentationManagerImpl.java?rev=684825&r1=684824&r2=684825&view=diff
==============================================================================
--- cxf/branches/2.0.x-fixes/rt/management/src/main/java/org/apache/cxf/management/jmx/InstrumentationManagerImpl.java (original)
+++ cxf/branches/2.0.x-fixes/rt/management/src/main/java/org/apache/cxf/management/jmx/InstrumentationManagerImpl.java Mon Aug 11 10:21:27 2008
@@ -75,7 +75,7 @@
         return bus;
     }
     
-    @Resource(name = "bus")
+    @Resource(name = "cxf")
     public void setBus(Bus bus) {        
         this.bus = bus;
     }

Modified: cxf/branches/2.0.x-fixes/rt/transports/http-jetty/src/main/java/org/apache/cxf/transport/http_jetty/JettyHTTPServerEngine.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.0.x-fixes/rt/transports/http-jetty/src/main/java/org/apache/cxf/transport/http_jetty/JettyHTTPServerEngine.java?rev=684825&r1=684824&r2=684825&view=diff
==============================================================================
--- cxf/branches/2.0.x-fixes/rt/transports/http-jetty/src/main/java/org/apache/cxf/transport/http_jetty/JettyHTTPServerEngine.java (original)
+++ cxf/branches/2.0.x-fixes/rt/transports/http-jetty/src/main/java/org/apache/cxf/transport/http_jetty/JettyHTTPServerEngine.java Mon Aug 11 10:21:27 2008
@@ -143,7 +143,7 @@
     /**
      * The bus.
      */
-    @Resource(name = "bus")
+    @Resource(name = "cxf")
     public void setBus(Bus b) {
         bus = b;
     }

Modified: cxf/branches/2.0.x-fixes/rt/transports/http-jetty/src/main/java/org/apache/cxf/transport/http_jetty/JettyHTTPServerEngineFactory.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.0.x-fixes/rt/transports/http-jetty/src/main/java/org/apache/cxf/transport/http_jetty/JettyHTTPServerEngineFactory.java?rev=684825&r1=684824&r2=684825&view=diff
==============================================================================
--- cxf/branches/2.0.x-fixes/rt/transports/http-jetty/src/main/java/org/apache/cxf/transport/http_jetty/JettyHTTPServerEngineFactory.java (original)
+++ cxf/branches/2.0.x-fixes/rt/transports/http-jetty/src/main/java/org/apache/cxf/transport/http_jetty/JettyHTTPServerEngineFactory.java Mon Aug 11 10:21:27 2008
@@ -86,9 +86,9 @@
      * This call is used to set the bus. It should only be called once.
      * @param bus
      */
-    @Resource(name = "bus")
+    @Resource(name = "cxf")
     public void setBus(Bus bus) {
-        assert this.bus == null;
+        assert this.bus == null || this.bus == bus;
         this.bus = bus;
     }
     

Modified: cxf/branches/2.0.x-fixes/rt/transports/http-jetty/src/main/java/org/apache/cxf/transport/http_jetty/JettyHTTPTransportFactory.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.0.x-fixes/rt/transports/http-jetty/src/main/java/org/apache/cxf/transport/http_jetty/JettyHTTPTransportFactory.java?rev=684825&r1=684824&r2=684825&view=diff
==============================================================================
--- cxf/branches/2.0.x-fixes/rt/transports/http-jetty/src/main/java/org/apache/cxf/transport/http_jetty/JettyHTTPTransportFactory.java (original)
+++ cxf/branches/2.0.x-fixes/rt/transports/http-jetty/src/main/java/org/apache/cxf/transport/http_jetty/JettyHTTPTransportFactory.java Mon Aug 11 10:21:27 2008
@@ -45,7 +45,7 @@
         super();
     }
     
-    @Resource(name = "bus")
+    @Resource(name = "cxf")
     public void setBus(Bus b) {
         super.setBus(b);
     }

Modified: cxf/branches/2.0.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/http/AbstractHTTPTransportFactory.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.0.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/http/AbstractHTTPTransportFactory.java?rev=684825&r1=684824&r2=684825&view=diff
==============================================================================
--- cxf/branches/2.0.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/http/AbstractHTTPTransportFactory.java (original)
+++ cxf/branches/2.0.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/http/AbstractHTTPTransportFactory.java Mon Aug 11 10:21:27 2008
@@ -88,7 +88,7 @@
      * This method is used by Spring to inject the bus.
      * @param b The CXF bus.
      */
-    @Resource(name = "bus")
+    @Resource(name = "cxf")
     public void setBus(Bus b) {
         bus = b;
     }

Modified: cxf/branches/2.0.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletTransportFactory.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.0.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletTransportFactory.java?rev=684825&r1=684824&r2=684825&view=diff
==============================================================================
--- cxf/branches/2.0.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletTransportFactory.java (original)
+++ cxf/branches/2.0.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletTransportFactory.java Mon Aug 11 10:21:27 2008
@@ -69,7 +69,7 @@
         controller = c;
     }
 
-    @Resource(name = "bus")
+    @Resource(name = "cxf")
     public void setBus(Bus b) {
         super.setBus(b);
     }

Modified: cxf/branches/2.0.x-fixes/rt/transports/jbi/src/main/java/org/apache/cxf/transport/jbi/JBITransportFactory.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.0.x-fixes/rt/transports/jbi/src/main/java/org/apache/cxf/transport/jbi/JBITransportFactory.java?rev=684825&r1=684824&r2=684825&view=diff
==============================================================================
--- cxf/branches/2.0.x-fixes/rt/transports/jbi/src/main/java/org/apache/cxf/transport/jbi/JBITransportFactory.java (original)
+++ cxf/branches/2.0.x-fixes/rt/transports/jbi/src/main/java/org/apache/cxf/transport/jbi/JBITransportFactory.java Mon Aug 11 10:21:27 2008
@@ -59,7 +59,7 @@
 
     private Collection<String> activationNamespaces;
 
-    @Resource(name = "bus")
+    @Resource(name = "cxf")
     public void setBus(Bus b) {
         bus = b;
     }

Modified: cxf/branches/2.0.x-fixes/rt/transports/jms/src/main/java/org/apache/cxf/transport/jms/JMSTransportFactory.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.0.x-fixes/rt/transports/jms/src/main/java/org/apache/cxf/transport/jms/JMSTransportFactory.java?rev=684825&r1=684824&r2=684825&view=diff
==============================================================================
--- cxf/branches/2.0.x-fixes/rt/transports/jms/src/main/java/org/apache/cxf/transport/jms/JMSTransportFactory.java (original)
+++ cxf/branches/2.0.x-fixes/rt/transports/jms/src/main/java/org/apache/cxf/transport/jms/JMSTransportFactory.java Mon Aug 11 10:21:27 2008
@@ -45,7 +45,7 @@
 
     private Bus bus;
 
-    @Resource(name = "bus")
+    @Resource(name = "cxf")
     public void setBus(Bus b) {
         bus = b;
     }

Modified: cxf/branches/2.0.x-fixes/rt/transports/local/src/main/java/org/apache/cxf/transport/local/LocalTransportFactory.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.0.x-fixes/rt/transports/local/src/main/java/org/apache/cxf/transport/local/LocalTransportFactory.java?rev=684825&r1=684824&r2=684825&view=diff
==============================================================================
--- cxf/branches/2.0.x-fixes/rt/transports/local/src/main/java/org/apache/cxf/transport/local/LocalTransportFactory.java (original)
+++ cxf/branches/2.0.x-fixes/rt/transports/local/src/main/java/org/apache/cxf/transport/local/LocalTransportFactory.java Mon Aug 11 10:21:27 2008
@@ -82,7 +82,7 @@
         messageIncludeProperties.add(Message.RESPONSE_CODE);
     }
     
-    @Resource(name = "bus")
+    @Resource(name = "cxf")
     public void setBus(Bus b) {
         bus = b;
     }

Modified: cxf/branches/2.0.x-fixes/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/MAPAggregator.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.0.x-fixes/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/MAPAggregator.java?rev=684825&r1=684824&r2=684825&view=diff
==============================================================================
--- cxf/branches/2.0.x-fixes/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/MAPAggregator.java (original)
+++ cxf/branches/2.0.x-fixes/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/MAPAggregator.java Mon Aug 11 10:21:27 2008
@@ -511,7 +511,7 @@
 
     private String getDelimiter(String uri) {
         if (uri.startsWith("urn")) {
-            return ".";
+            return ":";
         }
         return "/";
     }

Modified: cxf/branches/2.0.x-fixes/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/OperationProcessor.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.0.x-fixes/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/OperationProcessor.java?rev=684825&r1=684824&r2=684825&view=diff
==============================================================================
--- cxf/branches/2.0.x-fixes/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/OperationProcessor.java (original)
+++ cxf/branches/2.0.x-fixes/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/OperationProcessor.java Mon Aug 11 10:21:27 2008
@@ -42,7 +42,6 @@
 import org.apache.cxf.tools.common.model.JavaReturn;
 import org.apache.cxf.tools.common.model.JavaType;
 import org.apache.cxf.tools.wsdlto.frontend.jaxws.customization.JAXWSBinding;
-import org.apache.cxf.tools.wsdlto.frontend.jaxws.processor.internal.annotator.SoapBindingAnnotator;
 import org.apache.cxf.tools.wsdlto.frontend.jaxws.processor.internal.annotator.WebMethodAnnotator;
 import org.apache.cxf.tools.wsdlto.frontend.jaxws.processor.internal.annotator.WebResultAnnotator;
 import org.apache.cxf.tools.wsdlto.frontend.jaxws.processor.internal.annotator.WrapperAnnotator;
@@ -98,7 +97,6 @@
         }
 
         method.annotate(new WebResultAnnotator());
-        method.annotate(new SoapBindingAnnotator());                
 
         JAXWSBinding opBinding = (JAXWSBinding)operation.getExtensor(JAXWSBinding.class);
 

Modified: cxf/branches/2.0.x-fixes/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/annotator/BindingAnnotator.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.0.x-fixes/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/annotator/BindingAnnotator.java?rev=684825&r1=684824&r2=684825&view=diff
==============================================================================
--- cxf/branches/2.0.x-fixes/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/annotator/BindingAnnotator.java (original)
+++ cxf/branches/2.0.x-fixes/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/annotator/BindingAnnotator.java Mon Aug 11 10:21:27 2008
@@ -41,58 +41,89 @@
         if (processBinding(intf)) {
             JAnnotation bindingAnnotation = new JAnnotation(SOAPBinding.class);
             if (!SOAPBinding.Style.DOCUMENT.equals(intf.getSOAPStyle())) {
-                bindingAnnotation.addElement(new JAnnotationElement("style", intf.getSOAPStyle()));
+                bindingAnnotation.addElement(new JAnnotationElement("style",
+                                                                    intf.getSOAPStyle()));
             }
             if (!SOAPBinding.Use.LITERAL.equals(intf.getSOAPUse())) {
                 bindingAnnotation.addElement(new JAnnotationElement("use", intf.getSOAPUse()));
             }            
-            if (intf.getSOAPStyle() == SOAPBinding.Style.DOCUMENT) {
+            if (intf.getSOAPStyle() == SOAPBinding.Style.DOCUMENT
+                && intf.getSOAPParameterStyle() != SOAPBinding.ParameterStyle.WRAPPED) {
                 bindingAnnotation.addElement(new JAnnotationElement("parameterStyle", 
-                                                                           intf.getSOAPParameterStyle()));
+                                                                     intf.getSOAPParameterStyle()));
             }
             intf.addAnnotation(bindingAnnotation);
         }
+        
+        
+        for (JavaMethod method : intf.getMethods()) {
+            if (!method.isAsync()) {
+                method.annotate(new SoapBindingAnnotator());
+            }
+        }
     }
     
     private boolean processBinding(JavaInterface intf) {
         SOAPBinding.Style soapStyle = intf.getSOAPStyle();
         SOAPBinding.Use soapUse = intf.getSOAPUse();
-        boolean isWrapped = true;
-        int count = 0;
+        boolean allWrapped = true;
+        boolean allBare = true;
+        boolean allRPC = true;
+        boolean allDOC = true;
         for (JavaMethod method : intf.getMethods()) {
             if (!method.isWrapperStyle()) {
-                isWrapped = false;
-                count++;
+                allWrapped = false;
+            } else {
+                allBare = false;
+            }
+            SOAPBinding.Style mStyle = method.getSoapStyle();
+            if (mStyle == null) {
+                mStyle = soapStyle;
+            }
+            if (mStyle == null) {
+                mStyle = SOAPBinding.Style.DOCUMENT;
             }
             if (soapStyle == null
                 && method.getSoapStyle() != null) {
                 soapStyle = method.getSoapStyle();
             }
+            if (SOAPBinding.Style.DOCUMENT.equals(mStyle)) {
+                allRPC = false;
+            } else {
+                allDOC = false;
+            }
+          
             if (soapUse == null
                 && method.getSoapUse() != null) {
                 soapUse = method.getSoapUse();
             }
         }
+        if (allDOC) {
+            soapStyle = SOAPBinding.Style.DOCUMENT;
+        } else if (allRPC) {
+            soapStyle = SOAPBinding.Style.RPC;            
+        }
 
         if (soapStyle == SOAPBinding.Style.DOCUMENT) {
             intf.setSOAPStyle(SOAPBinding.Style.DOCUMENT);
-            if (isWrapped) {
+            if (allWrapped) {
                 intf.setSOAPParameterStyle(SOAPBinding.ParameterStyle.WRAPPED);
-            } else {
+            } else if (allBare) {
                 intf.setSOAPParameterStyle(SOAPBinding.ParameterStyle.BARE);
             }
         } else if (soapStyle == null) {
             intf.setSOAPStyle(SOAPBinding.Style.DOCUMENT);
-            if (isWrapped) {
+            if (allWrapped) {
                 intf.setSOAPParameterStyle(SOAPBinding.ParameterStyle.WRAPPED);
-            } else {
+            } else if (allBare) {
                 intf.setSOAPParameterStyle(SOAPBinding.ParameterStyle.BARE);
             }
-            
         } else {
             intf.setSOAPStyle(SOAPBinding.Style.RPC);
         }
-        
+        if (intf.getSOAPParameterStyle() == null) {
+            intf.setSOAPParameterStyle(SOAPBinding.ParameterStyle.WRAPPED);
+        }
         if (soapUse == SOAPBinding.Use.LITERAL) {
             intf.setSOAPUse(SOAPBinding.Use.LITERAL);
         } else if (soapUse == null) {
@@ -102,12 +133,6 @@
         }
 
         if (intf.getSOAPStyle() == SOAPBinding.Style.DOCUMENT
-            && count != 0
-            && count != intf.getMethods().size()) {
-            return false;
-        }
-
-        if (intf.getSOAPStyle() == SOAPBinding.Style.DOCUMENT
             && intf.getSOAPUse() == SOAPBinding.Use.LITERAL
             && intf.getSOAPParameterStyle() == SOAPBinding.ParameterStyle.WRAPPED) {
             return false;

Modified: cxf/branches/2.0.x-fixes/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/annotator/SoapBindingAnnotator.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.0.x-fixes/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/annotator/SoapBindingAnnotator.java?rev=684825&r1=684824&r2=684825&view=diff
==============================================================================
--- cxf/branches/2.0.x-fixes/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/annotator/SoapBindingAnnotator.java (original)
+++ cxf/branches/2.0.x-fixes/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/annotator/SoapBindingAnnotator.java Mon Aug 11 10:21:27 2008
@@ -51,6 +51,11 @@
                                                                         SOAPBinding.ParameterStyle.WRAPPED));
                 method.addAnnotation("SOAPBinding", bindingAnnotation);                
             }
+        } else if (!SOAPBinding.Style.RPC.equals(method.getInterface().getSOAPStyle())) {
+            JAnnotation bindingAnnotation = new JAnnotation(SOAPBinding.class);
+            bindingAnnotation.addElement(new JAnnotationElement("style", 
+                                                                       SOAPBinding.Style.RPC));
+            method.addAnnotation("SOAPBinding", bindingAnnotation);            
         }
     }
     

Modified: cxf/branches/2.0.x-fixes/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenBugTest.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.0.x-fixes/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenBugTest.java?rev=684825&r1=684824&r2=684825&view=diff
==============================================================================
--- cxf/branches/2.0.x-fixes/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenBugTest.java (original)
+++ cxf/branches/2.0.x-fixes/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenBugTest.java Mon Aug 11 10:21:27 2008
@@ -725,6 +725,8 @@
             String results = getStringFromFile(new File(output.getCanonicalPath(), 
                                                         "org/tempuri/GreeterRPCLit.java"));
             assertTrue(results.indexOf("@WebParam(partName  =  \"inInt\",  name  =  \"inInt\")") != -1);
+            assertTrue(results.indexOf("Style.RPC") != -1);
+            
         } catch (Exception e) {
             fail("The cxf978.wsdl is a valid wsdl, should pass the test, caused by: " + e.getMessage());
         }

Modified: cxf/branches/2.0.x-fixes/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.0.x-fixes/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java?rev=684825&r1=684824&r2=684825&view=diff
==============================================================================
--- cxf/branches/2.0.x-fixes/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java (original)
+++ cxf/branches/2.0.x-fixes/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java Mon Aug 11 10:21:27 2008
@@ -743,9 +743,11 @@
 
         Method method = clz.getMethod("inoutHeader", new Class[] {para, Holder.class});
 
-        soapBindingAnno = AnnotationUtil.getPrivMethodAnnotation(method, SOAPBinding.class);
-        assertNotNull(soapBindingAnno);
-        assertEquals(SOAPBinding.ParameterStyle.BARE, soapBindingAnno.parameterStyle());
+        //the SOAPBinding annotation on the class sets it to bare, thus, this annotation may
+        //not be generated as it would be redundant
+        //soapBindingAnno = AnnotationUtil.getPrivMethodAnnotation(method, SOAPBinding.class);
+        //assertNotNull(soapBindingAnno);
+        //assertEquals(SOAPBinding.ParameterStyle.BARE, soapBindingAnno.parameterStyle());
 
         WebParam webParamAnno = AnnotationUtil.getWebParam(method, "SOAPHeaderInfo");
         assertEquals("INOUT", webParamAnno.mode().name());

Modified: cxf/branches/2.0.x-fixes/tools/wsdlto/test/src/test/resources/wsdl2java_wsdl/bug978/bug.wsdl
URL: http://svn.apache.org/viewvc/cxf/branches/2.0.x-fixes/tools/wsdlto/test/src/test/resources/wsdl2java_wsdl/bug978/bug.wsdl?rev=684825&r1=684824&r2=684825&view=diff
==============================================================================
--- cxf/branches/2.0.x-fixes/tools/wsdlto/test/src/test/resources/wsdl2java_wsdl/bug978/bug.wsdl (original)
+++ cxf/branches/2.0.x-fixes/tools/wsdlto/test/src/test/resources/wsdl2java_wsdl/bug978/bug.wsdl Mon Aug 11 10:21:27 2008
@@ -33,7 +33,7 @@
     <wsdl:types/>
     
     <wsdl:binding name="Greeter_SOAPBinding_RPCLit" type="i0:GreeterRPCLit">
-	<soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
+	<soap:binding transport="http://schemas.xmlsoap.org/soap/http"/>
 	
 	<wsdl:operation name="sayHi">
 	    <soap:operation soapAction="" style="rpc"/>