Try putting xmlns:s="http://www.w3.org/2001/XMLSchema"; as an attribute
of the <s:schema> element.  Like so:

<s:schema xmlns:s=http://www.w3.org/2001/XMLSchema
          elementFormDefault="qualified" 
          targetNamespace="com.blah">

-Chris

-----Original Message-----
From: news [mailto:[EMAIL PROTECTED] On Behalf Of teknokrat
Sent: Tuesday, April 03, 2007 2:30 PM
To: [email protected]
Subject: [xfire-user] How to create a client for this service?

I have wsdl file that start like

<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions xmlns:http="http://schemas.xmlsoap.org/wsdl/http/";
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/";
xmlns:s="http://www.w3.org/2001/XMLSchema";
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/";
xmlns:tns="com.blah"
xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/";
xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/";
targetNamespace="com.blah"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/";>
   <wsdl:types>

     <s:schema elementFormDefault="qualified"
targetNamespace="com.blah">
       <s:import namespace="http://www.w3.org/2001/XMLSchema"; />

...

when I run WSGenTask on it I get errors such as

03-Apr-2007 19:25:22 org.codehaus.xfire.gen.jaxb.ErrorReceiverImpl error
SEVERE: undefined element declaration 's:schema' at 0,0 in 
file:/C:/dev/xfire-1.2.5/lib/my.wsdl#types?schema1
...

If I change the import element to

<s:import namespace="http://www.w3.org/2001/XMLSchema"; 
schemaLocation="http://www.w3.org/2001/XMLSchema.xsd"/>

I get the following errors

Retrieving schema at 'http://www.w3.org/2001/XMLSchema.xsd', relative to

'file:/C:/dev/xfire-1.2.5/lib/my.wsdl'.
Retrieving schema at 'http://www.w3.org/2001/xml.xsd', relative to 
'http://www.w3.org/2001/XMLSchema.xsd'.
03-Apr-2007 19:26:41 org.codehaus.xfire.gen.jaxb.ErrorReceiverImpl error
SEVERE: 'anyType' is already defined at 1319,18 in 
http://www.w3.org/2001/XMLSchema.xsd
03-Apr-2007 19:26:41 org.codehaus.xfire.gen.jaxb.ErrorReceiverImpl error
SEVERE: (related to above error) the first definition appears here at 
-1,-1 in null
...

What am I doing wrong here? I have managed to generate the client using 
axis 1.4 ok.

thanks



---------------------------------------------------------------------
To unsubscribe from this list please visit:

    http://xircles.codehaus.org/manage_email


---------------------------------------------------------------------
To unsubscribe from this list please visit:

    http://xircles.codehaus.org/manage_email

Reply via email to