I think you are right concerning the namespaces. I do put my own types into
my own namespaces for clarity, but I'm not sure if this is what you are
supposed to do. Anyway it will work using your own namespaces.

What we do is to use a valid URL as namespace and place the xsd files at
this URL, like the namespace for the 2001 schema.

cheers
-kims-

> -----Opprinnelig melding-----
> Fra: Mark Young [mailto:[EMAIL PROTECTED]]
> Sendt: 20. juni 2001 18:40
> Til: [EMAIL PROTECTED]
> Emne: Re: wsdl arrayOfString ms-soap-client
> 
> 
> kims & Oliver:
> 
> What kims suggests might work, but I don't think you really 
> mean to put your
> own complex type into the official XML schema namespace.  
> That is the effect
> of setting your targetNamespace to be the same as the 
> official XML schema
> namespace.   The theory behind kims' advice is sound, I 
> think:  you must put
> your complex type into some targetNamespace, and then must 
> later reference
> it in that same namespace.  Originally you were putting it 
> into your own
> targetNamespace, but referencing it in the official XML 
> schema namespace,
> where it did not live.  That definitely won't work.
> 
> But putting your private definitions into the official XML 
> schema namespace
> sort of defeats the purpose of namespaces, since there is 
> every opportunity
> for you to create a naming conflict for yourself.
> 
> 
> This is more like what I think you really want to do:
> 
> 
>  <definitions name="urn:KlickBlickOperator"
>              targetNamespace="urn:KlickBlickOperator"
>              xmlns:tns="urn:KlickBlickOperator"
>              xmlns:typens="urn:xml-klickblick"
>              xmlns:xsd="http://www.w3.org/2001/XMLSchema";
>              xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/";
>              xmlns="http://schemas.xmlsoap.org/wsdl/";>
> 
> ...
> 
>    <types>
>      <xsd:schema targetNamespace="urn:KlickBlickOperator"
>  xmlns:xsd='http://www.w3.org/2001/XMLSchema'>
>        <xsd:complexType name='ArrayOfstring'>
>          <xsd:complexContent>
>            <xsd:restriction base='SOAP-ENC:Array'>
>              <xsd:attribute ref="SOAP-ENC:arrayType"
>  arrayType="xsd:string"/>
>            </xsd:restriction>
>          </xsd:complexContent>
>        </xsd:complexType>
>      </xsd:schema>
>    </types>
> 
> ...
> 
> 
>    <!-- message declns -->
>    <message name='dummyResponse'>
>      <part name='Result' type='xsd:string'/>
>    </message>
>    <message name='dummyRequest'>
>      <part name='arg0' type='tns:ArrayOfstring'/>
>    </message>
> 
> ...
> 
> Regards, and please correct me if I am wrong,
> 
> Mark Young
> [EMAIL PROTECTED]
> 
> 
> ----- Original Message -----
> From: <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Wednesday, June 20, 2001 3:50 AM
> Subject: SV: wsdl arrayOfString ms-soap-client
> 
> 
> Try replacing the types with this: The targetNamespace should 
> be the same as
> xsd and arrayType should be xsd:string.
> 
>    <types>
>      <xsd:schema targetNamespace="http://www.w3.org/2001/XMLSchema";
>  xmlns:xsd='http://www.w3.org/2001/XMLSchema'>
>        <xsd:complexType name='ArrayOfstring'>
>          <xsd:complexContent>
>            <xsd:restriction base='SOAP-ENC:Array'>
>              <xsd:attribute ref="SOAP-ENC:arrayType"
>  arrayType="xsd:string"/>
>            </xsd:restriction>
>          </xsd:complexContent>
>        </xsd:complexType>
>      </xsd:schema>
>    </types>
> 
> cheers
> 
> -kims-
> 
> > -----Opprinnelig melding-----
> > Fra: Oliver Rettig [mailto:[EMAIL PROTECTED]]
> > Sendt: 20. juni 2001 10:37
> > Til: soap
> > Emne: wsdl arrayOfString ms-soap-client
> >
> >
> > Hallo,
> >
> > I´ve the following wsdl-file for access of my apache
> > soap-server with a
> > ms-client:
> >
> > <?xml version="1.0" encoding='UTF-8'?>
> >
> > <definitions name="urn:KlickBlickOperator"
> >              targetNamespace="urn:KlickBlickOperator"
> >              xmlns:typens="urn:xml-klickblick"
> >              xmlns:xsd="http://www.w3.org/2001/XMLSchema";
> >              xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/";
> >              xmlns="http://schemas.xmlsoap.org/wsdl/";>
> >
> >   <types>
> >     <xsd:schema targetNamespace="urn:xml-klickblick"
> > xmlns:xsd='http://www.w3.org/2001/XMLSchema'>
> >       <xsd:complexType name='ArrayOfstring'>
> >         <xsd:complexContent>
> >           <xsd:restriction base='SOAP-ENC:Array'>
> >             <xsd:attribute ref="SOAP-ENC:arrayType"
> > arrayType="xsd:string[]"/>
> >           </xsd:restriction>
> >         </xsd:complexContent>
> >       </xsd:complexType>
> >     </xsd:schema>
> >   </types>
> >
> >   <!-- message declns -->
> >   <message name='dummyResponse'>
> >     <part name='Result' type='xsd:string'/>
> >   </message>
> >   <message name='dummyRequest'>
> >     <part name='arg0' type='xsd:ArrayOfstring'/>
> >   </message>
> >
> >   <!-- port type declns -->
> >   <portType name="KlickBlickOperator">
> >     <operation name='dummy'>
> >         <input message='dummyRequest'/>
> >         <output message='dummyResponse'/>
> >     </operation>
> >   </portType>
> >
> >   <!-- binding declns -->
> >   <binding name="KlickBlickSOAPBinding" type="KlickBlickOperator">
> >     <soap:binding style="rpc"
> >                   transport="http://schemas.xmlsoap.org/soap/http"/>
> >     <operation name="dummy">
> >       <soap:operation soapAction=""/>
> >       <input>
> >       <soap:body use="encoded"
> >                    namespace="urn:KlickBlickOperator"
> >
> > encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
> >       </input>
> >       <output>
> >         <soap:body use="encoded"
> >                    namespace="urn:KlickBlickOperator"
> >
> > encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
> >       </output>
> >     </operation>
> >   </binding>
> >
> >   <!-- service decln -->
> >   <service name="KlickBlickOperator">
> >     <port name="KlickBlickOperator" binding="KlickBlickSOAPBinding">
> >       <soap:address
> > 
> location="http://server1.klickblick.de:8080/soap/servlet/rpcrouter"/>
> >     </port>
> >   </service>
> >
> > </definitions>
> >
> > and I get the error-message on my client:
> >
> > Canont initialize SoapClient, SoapMapper: The schema 
> definition with a
> > targetnamespace of
> > http://www.w3.org/2001/XMLSchema for SoapMapper ArrayOfstring
> > could not
> > be found.
> >
> > What to do? Have I forgotting something to declare in the wsdl-file?
> > ArrayOfString should be my own type.
> >
> > Please help.
> >
> > Oliver
> >
> >
> >
> 
> 

Reply via email to