Re: Confused and need help....

From: BJ <>
Date: Fri, 17 Aug 2007 10:17:57 -0700 (PDT)

Vivek, thanks for the response. Yes, I am using wscompile given wsdl to
generate java class but I am not using JAX-WS RI 2.1.1. Is it doable without


Vivek Pandey wrote:
> You mentioned wscompile, which was wsdl to java tool in JAX-RPC. If you
> are using JAX-WS RI 2.1.1 and beyond, you should not see this problem,
> provided your endpoint is either WSDL first, where wsimport will
> generate @XmlSeeAlso[1] with all the base and sub classes allowing base
> classes to be returned.
> If it is Java first case, then you need to annotate your endpoint class
> with @XmlSeeAlso, for example:
> @XmlSeeAlso(PaymentInfo.class, CreditCardPaymentInfo.class)
> Similarly you need to run wsimport on your client so that the stub is
> generated with @XmlSeeAlso annotations with all the relevant classes.
> -vivek.
> [1]
> BJ wrote:
>> In my webservice, I have a method called getPaymentInfo() that returns a
>> base
>> class PaymentInfo; it can also return CreditCardPaymentInfo class because
>> this class extends the PaymenInfo class.
>> My question is when I call this method, it always return the PaymentInfo
>> class and I know for sure it should return CreditCardPaymentInfo class.
>> I am using wscompile to generate the client stub. Is there any switch in
>> wscompile I need to turn on/off to be able to get the right class back.
>> Thanks in advance.
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

View this message in context:
Sent from the JAX-RPC - User mailing list archive at