axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Richard Emberson <ember...@phc.net>
Subject wsdl2java: union of simpleType
Date Sun, 28 Apr 2002 19:28:55 GMT
Using wsdl2java, latest cvs (as of yesterday), when attempt to produce
Java code for the following

    <xsd:simpleType name="VersionInfo">
        <xsd:union memberTypes="xsd:dateTime xsd:int"/>
    </xsd:simpleType>

I get a class with no instance variable(s) nor any getters or settors -
hard to (de)serialize.

If I try:

    <xsd:simpleType name="VersionInfo">
          <xsd:union>
            <xsd:simpleType>
              <xsd:restriction base="xsd:dateTime"/>
            </xsd:simpleType>
            <xsd:simpleType>
              <xsd:restriction base="xsd:int"/>
            </xsd:simpleType>
          </xsd:union>
    </xsd:simpleType>

I get:

java.io.IOException: urn:login:VersionInfo already exists
        at
org.apache.axis.wsdl.toJava.SymbolTable.symbolTablePut(SymbolTable.java:1781)

        at
org.apache.axis.wsdl.toJava.SymbolTable.createTypeFromDef(SymbolTable.java:749)

        at
org.apache.axis.wsdl.toJava.SymbolTable.addTypes(SymbolTable.java:568)
        at
org.apache.axis.wsdl.toJava.SymbolTable.addTypes(SymbolTable.java:638)
        at
org.apache.axis.wsdl.toJava.SymbolTable.addTypes(SymbolTable.java:638)
        at
org.apache.axis.wsdl.toJava.SymbolTable.addTypes(SymbolTable.java:638)
        at
org.apache.axis.wsdl.toJava.SymbolTable.addTypes(SymbolTable.java:638)
        at
org.apache.axis.wsdl.toJava.SymbolTable.addTypes(SymbolTable.java:638)
        at
org.apache.axis.wsdl.toJava.SymbolTable.addTypes(SymbolTable.java:638)
        at
org.apache.axis.wsdl.toJava.SymbolTable.populateTypes(SymbolTable.java:531)

        at
org.apache.axis.wsdl.toJava.SymbolTable.populate(SymbolTable.java:424)
        at
org.apache.axis.wsdl.toJava.SymbolTable.add(SymbolTable.java:330)
        at org.apache.axis.wsdl.toJava.Emitter.emit(Emitter.java:188)
        at org.apache.axis.wsdl.toJava.Emitter.emit(Emitter.java:155)
        at
org.apache.axis.wsdl.WSDL2Java$WSDLRunnable.run(WSDL2Java.java:725)
        at java.lang.Thread.run(Thread.java:536)

Last Summer when I wrote a wsdl2java transformer (I used XSL) I found
unions to be the
hardest part .... I guess its the hardest part of Axis also .... but any
help would still
be appreciated.

Richard


Mime
View raw message