cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ff...@apache.org
Subject svn commit: r520345 - in /incubator/cxf/trunk: rt/core/src/main/java/org/apache/cxf/wsdl11/ systests/src/test/java/org/apache/cxf/systest/jaxws/ testutils/src/main/java/org/apache/cxf/anonymous_complex_type/ testutils/src/main/java/org/apache/locator_t...
Date Tue, 20 Mar 2007 09:36:08 GMT
Author: ffang
Date: Tue Mar 20 02:36:07 2007
New Revision: 520345

URL: http://svn.apache.org/viewvc?view=rev&rev=520345
Log:
[CXF-471] wrapper element shouldn't contain element reference
                        

Modified:
    incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLServiceBuilder.java
    incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/ClientServerMiscTest.java
    incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/LocatorClientServerTest.java
    incubator/cxf/trunk/testutils/src/main/java/org/apache/cxf/anonymous_complex_type/AnonymousComplexTypeImpl.java
    incubator/cxf/trunk/testutils/src/main/java/org/apache/locator_test/LocatorServiceImpl.java
    incubator/cxf/trunk/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java

Modified: incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLServiceBuilder.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLServiceBuilder.java?view=diff&rev=520345&r1=520344&r2=520345
==============================================================================
--- incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLServiceBuilder.java
(original)
+++ incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLServiceBuilder.java
Tue Mar 20 02:36:07 2007
@@ -625,7 +625,7 @@
         if (type.getParticle() instanceof XmlSchemaSequence) {
             XmlSchemaSequence seq = (XmlSchemaSequence)type.getParticle();
             XmlSchemaObjectCollection items = seq.getItems();
-
+            boolean ret = true;
             for (int x = 0; x < items.getCount(); x++) {
                 XmlSchemaObject o = items.getItem(x);
                 if (!(o instanceof XmlSchemaElement)) {
@@ -641,6 +641,8 @@
                     MessagePartInfo mpi = wrapper.addMessagePart(el.getRefName());
                     mpi.setTypeQName(el.getRefName());
                     mpi.setXmlSchema(el);
+                    //element reference is not permitted for wrapper element
+                    ret = false;
                 } else {
                     // anonymous type
                     MessagePartInfo mpi = wrapper.addMessagePart(new QName(namespaceURI,
el.getName()));
@@ -650,7 +652,7 @@
                 }
             }
 
-            return true;
+            return ret;
         } else if (type.getParticle() == null) {
             return true;
         }

Modified: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/ClientServerMiscTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/ClientServerMiscTest.java?view=diff&rev=520345&r1=520344&r2=520345
==============================================================================
--- incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/ClientServerMiscTest.java
(original)
+++ incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/ClientServerMiscTest.java
Tue Mar 20 02:36:07 2007
@@ -26,8 +26,9 @@
 
 import org.apache.cxf.anonymous_complex_type.AnonymousComplexType;
 import org.apache.cxf.anonymous_complex_type.AnonymousComplexTypeService;
+import org.apache.cxf.anonymous_complex_type.RefSplitName;
+import org.apache.cxf.anonymous_complex_type.RefSplitNameResponse;
 import org.apache.cxf.anonymous_complex_type.SplitName;
-import org.apache.cxf.anonymous_complex_type.SplitNameResponse;
 import org.apache.cxf.anonymous_complex_type.SplitNameResponse.Names;
 import org.apache.cxf.jaxb_element_test.JaxbElementTest;
 import org.apache.cxf.jaxb_element_test.JaxbElementTest_Service;
@@ -75,10 +76,12 @@
         try {
             SplitName name = new SplitName();
             name.setName("Tom Li");
-            SplitNameResponse reply = act.refSplitName(name);
+            RefSplitName refName = new RefSplitName();
+            refName.setSplitName(name);
+            RefSplitNameResponse reply = act.refSplitName(refName);
             assertNotNull("no response received from service", reply);
-            assertEquals("Tom", reply.getNames().getFirst());
-            assertEquals("Li", reply.getNames().getSecond());
+            assertEquals("Tom", reply.getSplitNameResponse().getNames().getFirst());
+            assertEquals("Li", reply.getSplitNameResponse().getNames().getSecond());
         } catch (UndeclaredThrowableException ex) {
             throw (Exception) ex.getCause();
         }

Modified: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/LocatorClientServerTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/LocatorClientServerTest.java?view=diff&rev=520345&r1=520344&r2=520345
==============================================================================
--- incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/LocatorClientServerTest.java
(original)
+++ incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/LocatorClientServerTest.java
Tue Mar 20 02:36:07 2007
@@ -31,7 +31,7 @@
 
 import org.apache.locator.LocatorService;
 import org.apache.locator.LocatorService_Service;
-import org.apache.locator.query.QuerySelectType;
+import org.apache.locator.types.QueryEndpoints;
 import org.apache.locator_test.LocatorServiceImpl;
 import org.junit.BeforeClass;
 import org.junit.Test;
@@ -95,7 +95,7 @@
             
         port.listEndpoints();
 
-        port.queryEndpoints(new QuerySelectType());
+        port.queryEndpoints(new QueryEndpoints());
 
     }
 }

Modified: incubator/cxf/trunk/testutils/src/main/java/org/apache/cxf/anonymous_complex_type/AnonymousComplexTypeImpl.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/testutils/src/main/java/org/apache/cxf/anonymous_complex_type/AnonymousComplexTypeImpl.java?view=diff&rev=520345&r1=520344&r2=520345
==============================================================================
--- incubator/cxf/trunk/testutils/src/main/java/org/apache/cxf/anonymous_complex_type/AnonymousComplexTypeImpl.java
(original)
+++ incubator/cxf/trunk/testutils/src/main/java/org/apache/cxf/anonymous_complex_type/AnonymousComplexTypeImpl.java
Tue Mar 20 02:36:07 2007
@@ -46,9 +46,11 @@
         return null;
     }
 
-    public SplitNameResponse refSplitName(SplitName splitName) {
-        if (splitName.getName() != null) {
-            String name = splitName.getName();
+            
+
+    public RefSplitNameResponse refSplitName(RefSplitName refSplitName) {
+        if (refSplitName.getSplitName().getName() != null) {
+            String name = refSplitName.getSplitName().getName();
             SplitNameResponse.Names names = new SplitNameResponse.Names();
             int pos = name.indexOf(" ");
             SplitNameResponse response = null;
@@ -63,7 +65,9 @@
             }
             response = new SplitNameResponse();
             response.setNames(names);
-            return response;
+            RefSplitNameResponse refResponse = new RefSplitNameResponse();
+            refResponse.setSplitNameResponse(response);
+            return refResponse;
         }
         return null;
     }

Modified: incubator/cxf/trunk/testutils/src/main/java/org/apache/locator_test/LocatorServiceImpl.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/testutils/src/main/java/org/apache/locator_test/LocatorServiceImpl.java?view=diff&rev=520345&r1=520344&r2=520345
==============================================================================
--- incubator/cxf/trunk/testutils/src/main/java/org/apache/locator_test/LocatorServiceImpl.java
(original)
+++ incubator/cxf/trunk/testutils/src/main/java/org/apache/locator_test/LocatorServiceImpl.java
Tue Mar 20 02:36:07 2007
@@ -29,9 +29,10 @@
 
 import org.apache.locator.EndpointNotExistFault;
 import org.apache.locator.LocatorService;
-import org.apache.locator.query.QuerySelectType;
 import org.apache.locator.types.EndpointIdentity;
 import org.apache.locator.types.ListEndpointsResponse.Endpoint;
+import org.apache.locator.types.QueryEndpoints;
+import org.apache.locator.types.QueryEndpointsResponse;
 
 
 /**
@@ -87,8 +88,8 @@
     }
 
     
-    public List<org.apache.locator.types.QueryEndpointsResponse.Endpoint> queryEndpoints(
-        QuerySelectType select) {
+    
+    public QueryEndpointsResponse queryEndpoints(QueryEndpoints parameters) {
         LOG.info("Executing operation queryEndpoints");
         return null;
     }

Modified: incubator/cxf/trunk/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java?view=diff&rev=520345&r1=520344&r2=520345
==============================================================================
--- incubator/cxf/trunk/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java
(original)
+++ incubator/cxf/trunk/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java
Tue Mar 20 02:36:07 2007
@@ -782,13 +782,13 @@
         assertTrue("Webservice annotation wsdlLocation should begin with file", ws.wsdlLocation()
                    .startsWith("file"));
 
-        Class<?> paraClass = classLoader.loadClass("org.apache.locator.query.QuerySelectType");
+        Class<?> paraClass = classLoader.loadClass("org.apache.locator.types.QueryEndpoints");
         Method method = clz.getMethod("queryEndpoints", new Class[] {paraClass});
         WebResult webRes = AnnotationUtil.getPrivMethodAnnotation(method, WebResult.class);
-        assertEquals("http://www.w3.org/2005/08/addressing", webRes.targetNamespace());
-        assertEquals("EndpointReference", webRes.name());
-        WebParam webParamAnn = AnnotationUtil.getWebParam(method, "select");
-        assertEquals("http://apache.org/locator/query", webParamAnn.targetNamespace());
+        assertEquals("http://apache.org/locator/types", webRes.targetNamespace());
+        assertEquals("queryEndpointsResponse", webRes.name());
+        WebParam webParamAnn = AnnotationUtil.getWebParam(method, "queryEndpoints");
+        assertEquals("http://apache.org/locator/types", webParamAnn.targetNamespace());
 
         method = clz.getMethod("deregisterPeerManager", new Class[] {String.class});
         webParamAnn = AnnotationUtil.getWebParam(method, "node_id");



Mime
View raw message