axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kevin Jones" <kev...@develop.com>
Subject SimpleType Code Generation Bug?
Date Wed, 19 May 2004 14:40:37 GMT
I'm using 1.2 Beta, this worked in 1.1

I have a WSDL doc that contains a schema and I'm running WSDL2Java -server.
The schema contains a simple type that is a parameter to one of the
'methods' on the web service. The SimpleType looks like this:

<xsd:simpleType name="ISBNType">
    <xsd:restriction base="xsd:string">
        <xsd:pattern value="[0-9]{3}-[0-9]{3}"/>
    </xsd:restriction>
</xsd:simpleType>

<xsd:element name="BookAvailabilityByISBN" type="tns:ISBNType"/>

and then the WSDL has this

<message name="getBookAvailabilityByISBNMsg">
    <part name="parameters" element="operations:BookAvailabilityByISBN"/>
</message>

The generated Java for this looks like

public AvailabilityDetails getBookAvailabilityByISBN(String parameters)
throws java.rmi.RemoteException;

i.e. it is defined as taking a String and no ISBNType Java type is defined. 

The WSDD looks like this

<typeMapping
    xmlns:ns="urn:com.develop.ejws:orinoco"
    qname="ns:ISBNType"
    type="java:java.lang.String"
    serializer="org.apache.axis.encoding.ser.SimpleSerializerFactory"
    deserializer="org.apache.axis.encoding.ser.SimpleDeserializerFactory"
    encodingStyle=""
/>

and when I browse to the generated WSDL (I'm letting the server re-generate
the WSDL) I get the following

<element name="BookAvailabilityByISBN" type="tns1:ISBNType"/>

but no ISBNType is defined in the WSDL/Schema

Is this a known bug/feature?

Thanks, 

Kevin Jones
http://kevinj.develop.com 


Mime
View raw message