Author: gnodet
Date: Wed May 16 14:20:13 2007
New Revision: 538738

URL: http://svn.apache.org/viewvc?view=rev&rev=538738
Log:
Fix wsdl-first demo

Modified:
    incubator/servicemix/branches/servicemix-3.1/samples/wsdl-first/client.html
    
incubator/servicemix/branches/servicemix-3.1/samples/wsdl-first/wsdl-first-jsr181-su/src/main/java/org/apache/servicemix/samples/wsdl_first/PersonImpl.java
    
incubator/servicemix/branches/servicemix-3.1/samples/wsdl-first/wsdl-first-jsr181-su/src/main/resources/person.wsdl
    
incubator/servicemix/branches/servicemix-3.1/samples/wsdl-first/wsdl-first-jsr181-su/src/main/resources/xbean.xml

Modified: 
incubator/servicemix/branches/servicemix-3.1/samples/wsdl-first/client.html
URL: 
http://svn.apache.org/viewvc/incubator/servicemix/branches/servicemix-3.1/samples/wsdl-first/client.html?view=diff&rev=538738&r1=538737&r2=538738
==============================================================================
--- incubator/servicemix/branches/servicemix-3.1/samples/wsdl-first/client.html 
(original)
+++ incubator/servicemix/branches/servicemix-3.1/samples/wsdl-first/client.html 
Wed May 16 14:20:13 2007
@@ -112,9 +112,9 @@
 <env:Envelope xmlns:env="http://schemas.xmlsoap.org/soap/envelope/";
               
xmlns:tns="http://servicemix.apache.org/samples/wsdl-first/types";>
   <env:Body>
-    <tns:GetPerson>
+    <tns:GetPersonRequest>
       <tns:personId>world</tns:personId>
-    </tns:GetPerson>
+    </tns:GetPersonRequest>
   </env:Body>
 </env:Envelope>
 

Modified: 
incubator/servicemix/branches/servicemix-3.1/samples/wsdl-first/wsdl-first-jsr181-su/src/main/java/org/apache/servicemix/samples/wsdl_first/PersonImpl.java
URL: 
http://svn.apache.org/viewvc/incubator/servicemix/branches/servicemix-3.1/samples/wsdl-first/wsdl-first-jsr181-su/src/main/java/org/apache/servicemix/samples/wsdl_first/PersonImpl.java?view=diff&rev=538738&r1=538737&r2=538738
==============================================================================
--- 
incubator/servicemix/branches/servicemix-3.1/samples/wsdl-first/wsdl-first-jsr181-su/src/main/java/org/apache/servicemix/samples/wsdl_first/PersonImpl.java
 (original)
+++ 
incubator/servicemix/branches/servicemix-3.1/samples/wsdl-first/wsdl-first-jsr181-su/src/main/java/org/apache/servicemix/samples/wsdl_first/PersonImpl.java
 Wed May 16 14:20:13 2007
@@ -17,25 +17,25 @@
 package org.apache.servicemix.samples.wsdl_first;
 
 import javax.jws.WebService;
-import javax.xml.ws.Holder;
 
-import org.apache.servicemix.samples.wsdl_first.types.GetPerson;
+import org.apache.servicemix.samples.wsdl_first.types.GetPersonRequest;
 import org.apache.servicemix.samples.wsdl_first.types.GetPersonResponse;
 
 @WebService(serviceName = "PersonService", targetNamespace = 
"http://servicemix.apache.org/samples/wsdl-first";, endpointInterface = 
"org.apache.servicemix.samples.wsdl_first.Person")
 public class PersonImpl implements Person {
 
-    public String getPerson(String personId, Holder<String> ssn, 
Holder<String> name)
-        throws UnknownPersonFault
-    {
+    public GetPersonResponse getPerson(GetPersonRequest payload) throws 
UnknownPersonFault {
+        String personId = payload.getPersonId();
         if (personId == null || personId.length() == 0) {
             org.apache.servicemix.samples.wsdl_first.types.UnknownPersonFault 
fault = new org.apache.servicemix.samples.wsdl_first.types.UnknownPersonFault();
             fault.setPersonId(personId);
             throw new UnknownPersonFault(null, fault);
         }
-        name.value = "Guillaume";
-        ssn.value = "000-000-0000";
-        return personId;
+        GetPersonResponse response = new GetPersonResponse();
+        response.setPersonId(payload.getPersonId());
+        response.setName("Guillaume");
+        response.setSsn("000-000-0000");
+        return response;
     }
 
 }

Modified: 
incubator/servicemix/branches/servicemix-3.1/samples/wsdl-first/wsdl-first-jsr181-su/src/main/resources/person.wsdl
URL: 
http://svn.apache.org/viewvc/incubator/servicemix/branches/servicemix-3.1/samples/wsdl-first/wsdl-first-jsr181-su/src/main/resources/person.wsdl?view=diff&rev=538738&r1=538737&r2=538738
==============================================================================
--- 
incubator/servicemix/branches/servicemix-3.1/samples/wsdl-first/wsdl-first-jsr181-su/src/main/resources/person.wsdl
 (original)
+++ 
incubator/servicemix/branches/servicemix-3.1/samples/wsdl-first/wsdl-first-jsr181-su/src/main/resources/person.wsdl
 Wed May 16 14:20:13 2007
@@ -19,78 +19,78 @@
 -->
 <!-- $Rev: 356052 $ $Date: 2005-12-11 14:41:20 -0800 (dim., 11 déc. 2005) 
$ -->
 <wsdl:definitions name="wsdl-first"
-       xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/";
-       xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/";
-       xmlns:xsd="http://www.w3.org/2001/XMLSchema";
-       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
-       xmlns:tns="http://servicemix.apache.org/samples/wsdl-first";
-       xmlns:typens="http://servicemix.apache.org/samples/wsdl-first/types";
-       targetNamespace="http://servicemix.apache.org/samples/wsdl-first";>
+   xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/";
+   xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/";
+   xmlns:xsd="http://www.w3.org/2001/XMLSchema";
+   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
+   xmlns:tns="http://servicemix.apache.org/samples/wsdl-first";
+   xmlns:typens="http://servicemix.apache.org/samples/wsdl-first/types";
+   targetNamespace="http://servicemix.apache.org/samples/wsdl-first";>
 
-       <wsdl:types>
-               <xsd:schema 
targetNamespace="http://servicemix.apache.org/samples/wsdl-first/types";
-                           elementFormDefault="qualified">
-                       <xsd:element name="GetPerson">
-                         <xsd:complexType>
-                                       <xsd:sequence>
-                                               <xsd:element name="personId" 
type="xsd:string"/>
-                                       </xsd:sequence>
-                               </xsd:complexType>
-                       </xsd:element>
-                       <xsd:element name="GetPersonResponse">
-                         <xsd:complexType>
-                                       <xsd:sequence>
-                                           <xsd:element name="personId" 
type="xsd:string"/>
-                                               <xsd:element name="ssn" 
type="xsd:string"/>
-                                               <xsd:element name="name" 
type="xsd:string"/>
-                                       </xsd:sequence>
-                               </xsd:complexType>
-                       </xsd:element>
-                       <xsd:element name="UnknownPersonFault">
-                         <xsd:complexType>
-                                       <xsd:sequence>
-                                           <xsd:element name="personId" 
type="xsd:string"/>
-                                       </xsd:sequence>
-                               </xsd:complexType>
-                       </xsd:element>
-               </xsd:schema>
-  </wsdl:types>
-       
-       <wsdl:message name="GetPersonRequest">
-               <wsdl:part name="payload" element="typens:GetPerson"/>
-       </wsdl:message>
-       <wsdl:message name="GetPersonResponse">
-               <wsdl:part name="payload" element="typens:GetPersonResponse"/>
-       </wsdl:message>
-       <wsdl:message name="UnknownPersonFault">
-               <wsdl:part name="payload" element="typens:UnknownPersonFault"/>
-       </wsdl:message>
+   <wsdl:types>
+      <xsd:schema 
targetNamespace="http://servicemix.apache.org/samples/wsdl-first/types";
+                  elementFormDefault="qualified">
+         <xsd:element name="GetPersonRequest">
+            <xsd:complexType>
+               <xsd:sequence>
+                  <xsd:element name="personId" type="xsd:string"/>
+               </xsd:sequence>
+            </xsd:complexType>
+         </xsd:element>
+         <xsd:element name="GetPersonResponse">
+            <xsd:complexType>
+               <xsd:sequence>
+                  <xsd:element name="personId" type="xsd:string"/>
+                  <xsd:element name="ssn" type="xsd:string"/>
+                  <xsd:element name="name" type="xsd:string"/>
+               </xsd:sequence>
+            </xsd:complexType>
+         </xsd:element>
+         <xsd:element name="UnknownPersonFault">
+            <xsd:complexType>
+               <xsd:sequence>
+                  <xsd:element name="personId" type="xsd:string"/>
+               </xsd:sequence>
+            </xsd:complexType>
+         </xsd:element>
+      </xsd:schema>
+   </wsdl:types>
 
-    <wsdl:portType name="Person">
-               <wsdl:operation name="GetPerson">
-                       <wsdl:input message="tns:GetPersonRequest"/>
-                       <wsdl:output message="tns:GetPersonResponse"/>
-                       <wsdl:fault name="UnknownPerson" 
message="tns:UnknownPersonFault"/>
-               </wsdl:operation>
-       </wsdl:portType>
-       
-    <wsdl:binding name="PersonSOAPBinding" type="tns:Person">
-       <soap:binding style="document" 
transport="http://schemas.xmlsoap.org/soap/http"; />
-               <wsdl:operation name="GetPerson">
-                       <wsdl:input>
-                               <soap:body use="literal" />
-                       </wsdl:input>
-                       <wsdl:output>
-                               <soap:body use="literal" />
-                       </wsdl:output>
-                       <wsdl:fault name="UnknownPerson">
-                               <soap:fault use="literal" name="UnknownPerson" 
/>
-                       </wsdl:fault>
-       </wsdl:operation>
+   <wsdl:message name="GetPersonRequest">
+      <wsdl:part name="payload" element="typens:GetPersonRequest"/>
+   </wsdl:message>
+   <wsdl:message name="GetPersonResponse">
+      <wsdl:part name="payload" element="typens:GetPersonResponse"/>
+   </wsdl:message>
+   <wsdl:message name="UnknownPersonFault">
+      <wsdl:part name="payload" element="typens:UnknownPersonFault"/>
+   </wsdl:message>
+
+   <wsdl:portType name="Person">
+      <wsdl:operation name="GetPerson">
+         <wsdl:input message="tns:GetPersonRequest"/>
+         <wsdl:output message="tns:GetPersonResponse"/>
+         <wsdl:fault name="UnknownPerson" message="tns:UnknownPersonFault"/>
+      </wsdl:operation>
+   </wsdl:portType>
+
+   <wsdl:binding name="PersonSOAPBinding" type="tns:Person">
+      <soap:binding style="document" 
transport="http://schemas.xmlsoap.org/soap/http"; />
+      <wsdl:operation name="GetPerson">
+         <wsdl:input>
+            <soap:body use="literal" />
+         </wsdl:input>
+         <wsdl:output>
+            <soap:body use="literal" />
+         </wsdl:output>
+         <wsdl:fault name="UnknownPerson">
+            <soap:fault use="literal" name="UnknownPerson" />
+         </wsdl:fault>
+      </wsdl:operation>
    </wsdl:binding>
 
-       <wsdl:service name="PersonService">
-       <wsdl:port binding="tns:PersonSOAPBinding" name="soap">
+   <wsdl:service name="PersonService">
+       <wsdl:port binding="tns:PersonSOAPBinding" name="soap">
            <soap:address location="http://localhost:8192/PersonService/"; />
        </wsdl:port>
    </wsdl:service>

Modified: 
incubator/servicemix/branches/servicemix-3.1/samples/wsdl-first/wsdl-first-jsr181-su/src/main/resources/xbean.xml
URL: 
http://svn.apache.org/viewvc/incubator/servicemix/branches/servicemix-3.1/samples/wsdl-first/wsdl-first-jsr181-su/src/main/resources/xbean.xml?view=diff&rev=538738&r1=538737&r2=538738
==============================================================================
--- 
incubator/servicemix/branches/servicemix-3.1/samples/wsdl-first/wsdl-first-jsr181-su/src/main/resources/xbean.xml
 (original)
+++ 
incubator/servicemix/branches/servicemix-3.1/samples/wsdl-first/wsdl-first-jsr181-su/src/main/resources/xbean.xml
 Wed May 16 14:20:13 2007
@@ -19,6 +19,8 @@
 -->
 <beans xmlns:jsr181="http://servicemix.apache.org/jsr181/1.0";>
 
-    <jsr181:endpoint 
pojoClass="org.apache.servicemix.samples.wsdl_first.PersonImpl" />
+    <jsr181:endpoint 
pojoClass="org.apache.servicemix.samples.wsdl_first.PersonImpl"
+                     wsdlResource="classpath:person.wsdl"
+                     style="document" />
 
 </beans>


Reply via email to