axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From remko de knikker <remko.deknik...@yale.edu>
Subject Re: how to include schema in generated wsdl?
Date Fri, 11 Apr 2003 19:48:45 GMT
Thanks for responding, but the <types> element is generated by Axis, and 
I don't know how to influence the generation so that it will include the 
Schema.
When triggering the generation with the URL?wsdl query, axis doesn't 
generate the <type> tag. How do I include it?? Or in general, how do I 
influence the wsdl generation??

r

Here's my complete wsdl:

<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions targetNamespace="http://130.132.79.42:8080/axis/services/Test3" xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:apachesoap="http://xml.apache.org/xml-soap" xmlns:impl="http://130.132.79.42:8080/axis/services/Test3"
xmlns:intf="http://130.132.79.42:8080/axis/services/Test3" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"><wsdl:types><schema targetNamespace=""
xmlns="http://www.w3.org/2001/XMLSchema"><import namespace="http://schemas.xmlsoap.org/soap/encoding/"/><element
name="method1" type="xsd:anyType"/><element name="method1Return" type="xsd:anyType"/><element
name="method3" type="xsd:anyType"/><element name="method3Return" type="xsd:anyType"/></schema></wsdl:types>
  <wsdl:message name="method3Request">
    <wsdl:part element="method3" name="part"/>
  </wsdl:message>
  <wsdl:message name="method1Response">
    <wsdl:part element="method1Return" name="method1Return"/>
  </wsdl:message>
  <wsdl:message name="method1Request">
    <wsdl:part element="method1" name="part"/>

  </wsdl:message>
  <wsdl:message name="method3Response">
    <wsdl:part element="method3Return" name="method3Return"/>
  </wsdl:message>
  <wsdl:portType name="Test3">
    <wsdl:operation name="method1">
      <wsdl:input message="impl:method1Request" name="method1Request"/>
      <wsdl:output message="impl:method1Response" name="method1Response"/>
    </wsdl:operation>

    <wsdl:operation name="method3">
      <wsdl:input message="impl:method3Request" name="method3Request"/>
      <wsdl:output message="impl:method3Response" name="method3Response"/>
    </wsdl:operation>
  </wsdl:portType>
  <wsdl:binding name="Test3SoapBinding" type="impl:Test3">
    <wsdlsoap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
    <wsdl:operation name="method1">
      <wsdlsoap:operation soapAction=""/>

      <wsdl:input name="method1Request">
        <wsdlsoap:body namespace="http://130.132.79.42:8080/axis/services/Test3" use="literal"/>
      </wsdl:input>
      <wsdl:output name="method1Response">
        <wsdlsoap:body namespace="http://130.132.79.42:8080/axis/services/Test3" use="literal"/>
      </wsdl:output>
    </wsdl:operation>
    <wsdl:operation name="method3">
      <wsdlsoap:operation soapAction=""/>

      <wsdl:input name="method3Request">
        <wsdlsoap:body namespace="http://130.132.79.42:8080/axis/services/Test3" use="literal"/>
      </wsdl:input>
      <wsdl:output name="method3Response">
        <wsdlsoap:body namespace="http://130.132.79.42:8080/axis/services/Test3" use="literal"/>
      </wsdl:output>
    </wsdl:operation>
  </wsdl:binding>
  <wsdl:service name="Test3Service">

    <wsdl:port binding="impl:Test3SoapBinding" name="Test3">
      <wsdlsoap:address location="http://130.132.79.42:8080/axis/services/Test3"/>
    </wsdl:port>
  </wsdl:service>
</wsdl:definitions>




Anne Thomas Manes wrote:

>You specify schema information in the <types> element.
>
><types>
>  <xs:schema targetNamespace="some-uri"
>     xmlns:xs="schema-namespace">
>     <xs:element name="requestmsg1">
>         <xs:complexType>
>             <xs:sequence>
>                 <xs:element name="spotid" minOccurs="1" type="xs:string"/>
>             </xs:sequence>
>     </xs:complexType>
>  </xs:schema>
></types>
>
><wsdl:message name="method1Request">
>  <wsdl:part element="requestmsg1" name="part"/>
></wsdl:message>
>
>Keep in mind that in the <part> definition you use element with doc/literal
>and type with rpc/encoded.
>
>Regards,
>Anne
>
>  
>
>>-----Original Message-----
>>From: remko de knikker [mailto:remko.deknikker@yale.edu]
>>Sent: Friday, April 11, 2003 3:08 PM
>>To: axis-user group
>>Subject: how to include schema in generated wsdl?
>>
>>
>>My wsdl describes the parts of my services' message, but only the
>>method's input-parameter. How do I include the whole XML structure's
>>meta-data or its XML Schema so that the client knows what the input is
>>required to look like????
>>now:
>>
>>  <wsdl:message name="method1Request">
>>    <wsdl:part element="method1" name="part"/>
>>  </wsdl:message>
>>
>>should say something like my schema design:
>>
>>    <xs:element name="requestmsg1">
>>        <xs:complexType>
>>            <xs:sequence>
>>                <xs:element name="spotid" minOccurs="1" type="xs:string"/>
>>            </xs:sequence>
>>    </xs:complexType>>
>>thanks,
>>
>>r
>>
>>    
>>
>
>
>  
>


Mime
View raw message