users@jax-rpc.java.net

Re: Class not generated

From: Matt Swensson <matman2k1_at_yahoo.com>
Date: Fri, 8 Apr 2005 12:01:10 -0700 (PDT)

Sure!

<s:complexType name="Item" abstract="true">
 <s:attribute name="ID" type="s:string" use="required"/>
 <s:attribute name="Name" type="s:string"/>
</s:complexType>

So, Item is abstract, but
Item.java
Item_InterfaceSOAPSerializer.java
Item_LiteralSerializer.java

are getting generated, but not Book.

There are other items in the WSDL that extend Item and get generated
fine, but they have the format of the second example I showed (with a
sequence of elements and not attributes).

Thanks for your help,
Matt


--- Doug Kohlert <Doug.Kohlert_at_Sun.COM> wrote:
> Can you send the definition of tns:Item and anything that it might
> extend?
>
> Matt Swensson wrote:
>
> >I have a wsdl file that contains:
> ><s:complexType name="ArrayOfBook">
> > <s:sequence>
> > <s:element minOccurs="0" maxOccurs="unbounded" name="BookSlot"
> >nillable="true" type="tns:Book"/>
> > </s:sequence>
> ></s:complexType>
> >
> ><s:complexType name="Book">
> > <s:complexContent mixed="false">
> > <s:extension base="tns:Item">
> > <s:attribute name="numPages" type="s:string" use="required"/>
> > </s:extension>
> > </s:complexContent>
> ></s:complexType>
> >
> >and I am using wscompile on it:
> >wscompile.sh -s src/ -d classes/ -gen:client -keep
> >-f:explicitcontext,searchschema -verbose bin/config.xml
> >
> >But the Book class never gets generated, only:
> >ArrayOfBook.java
> >ArrayOfBook_LiteralSerializer.java
> >
> >and in that class it has:
> >protected javax.xml.soap.SOAPElement[] BookSlot
> >
> >If I change the WSDL to have this:
> ><s:complexType name="ArrayOfBook">
> > <s:sequence>
> > <s:element minOccurs="0" maxOccurs="unbounded" name="BookSlot"
> >nillable="true" type="tns:Book"/>
> > </s:sequence>
> ></s:complexType>
> >
> ><s:complexType name="Book">
> > <s:complexContent mixed="false">
> > <s:extension base="tns:Item">
> > <s:sequence>
> > <s:element minOccurs="1" maxOccurs="1" name="numPages"
> >type="s:string"/>
> > </s:sequence>
> > </s:extension>
> > </s:complexContent>
> ></s:complexType>
> >
> >The classes generate fine.
> >ArrayOfBook.java
> >ArrayOfBook_LiteralSerializer.java
> >Book.java
> >Book_LiteralSerializer.java
> >
> >and the ArrayOfBook.java file contains:
> >protected blah.blah.blah.Book[] BookSlot
> >
> >The first example is valid according to examples on W3C's site, but
> the
> >wscompile tool doesn't seem to like it and I'm wondering if anyone
> >knows why.
> >
> >Thanks,
> >Matt
> >
> >
> >
> >
> >
> >__________________________________
> >Do you Yahoo!?
> >Yahoo! Personals - Better first dates. More second dates.
> >http://personals.yahoo.com
> >
> >
>
>---------------------------------------------------------------------
> >To unsubscribe, e-mail: users-unsubscribe_at_jax-rpc.dev.java.net
> >For additional commands, e-mail: users-help_at_jax-rpc.dev.java.net
> >
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_jax-rpc.dev.java.net
> For additional commands, e-mail: users-help_at_jax-rpc.dev.java.net
>
>


                
__________________________________
Do you Yahoo!?
Yahoo! Personals - Better first dates. More second dates.
http://personals.yahoo.com