You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cxf.apache.org by Thorsten Kraus <Th...@gmx.net> on 2007/12/01 18:48:19 UTC
Annotations
Hello,
I have a method which has a custom bean object in its signature. This
method should be accessable via SOAP.
I want to mark some attributes of this bean object as required and some
other attributes I don't want to include in the request --> these
attributes should not exist in the generated WSDL.
Can someone tell me how I can annotate this attributes that the needed
behaviour is generated?
Regards,
TMK
Re: Annotations
Posted by Willem Jiang <ni...@iona.com>.
Hi,
I do not think JAXB's annotation can implment the behavior that you want.
Maybe you can define a parent class to be used in the method A, and a
child class which extends the parent class with addition attributes to
be used in the method B.
Cheers,
Willem.
Thorsten Kraus wrote:
> Thanks a lot for your answer! The overview of the annotation types
> helpes me very much.
> Perhaps you could give me an advice for the following problem: I have
> two methods which use the same bean class. In one method, I want to
> use all attributes of the bean. In the other method, I want to use
> only a subset of the bean attributes in my web service request. Is
> there a possibility to annotate the attributes or the corresponding
> methods to implement this behaviour?
>
> Regards,
> TMK
>
> Jiang, Ning (Willem) schrieb:
>> Hi,
>>
>> You can take a look at this doc[1] which is useful for working on the
>> JAXB2 annotation.
>> [1]http://www.caucho.com/resin-3.1/doc/jaxb-annotations.xtp
>>
>> Willem.
>>
>> -----Original Message-----
>> From: Thorsten Kraus [mailto:ThorstenKraus@gmx.net]
>> Sent: Sun 12/2/2007 1:48
>> To: cxf-user@incubator.apache.org
>> Subject: Annotations
>>
>> Hello,
>>
>> I have a method which has a custom bean object in its signature. This
>> method should be accessable via SOAP.
>> I want to mark some attributes of this bean object as required and
>> some other attributes I don't want to include in the request -->
>> these attributes should not exist in the generated WSDL.
>> Can someone tell me how I can annotate this attributes that the
>> needed behaviour is generated?
>>
>> Regards,
>> TMK
>>
>>
>
Re: Annotations
Posted by Thorsten Kraus <TK...@gmx.de>.
Thanks a lot for your answer! The overview of the annotation types
helpes me very much.
Perhaps you could give me an advice for the following problem: I have
two methods which use the same bean class. In one method, I want to use
all attributes of the bean. In the other method, I want to use only a
subset of the bean attributes in my web service request. Is there a
possibility to annotate the attributes or the corresponding methods to
implement this behaviour?
Regards,
TMK
Jiang, Ning (Willem) schrieb:
> Hi,
>
> You can take a look at this doc[1] which is useful for working on the JAXB2 annotation.
> [1]http://www.caucho.com/resin-3.1/doc/jaxb-annotations.xtp
>
> Willem.
>
> -----Original Message-----
> From: Thorsten Kraus [mailto:ThorstenKraus@gmx.net]
> Sent: Sun 12/2/2007 1:48
> To: cxf-user@incubator.apache.org
> Subject: Annotations
>
> Hello,
>
> I have a method which has a custom bean object in its signature. This
> method should be accessable via SOAP.
> I want to mark some attributes of this bean object as required and some
> other attributes I don't want to include in the request --> these
> attributes should not exist in the generated WSDL.
> Can someone tell me how I can annotate this attributes that the needed
> behaviour is generated?
>
> Regards,
> TMK
>
>
RE: Annotations
Posted by "Jiang, Ning (Willem)" <Ni...@iona.com>.
Hi,
You can take a look at this doc[1] which is useful for working on the JAXB2 annotation.
[1]http://www.caucho.com/resin-3.1/doc/jaxb-annotations.xtp
Willem.
-----Original Message-----
From: Thorsten Kraus [mailto:ThorstenKraus@gmx.net]
Sent: Sun 12/2/2007 1:48
To: cxf-user@incubator.apache.org
Subject: Annotations
Hello,
I have a method which has a custom bean object in its signature. This
method should be accessable via SOAP.
I want to mark some attributes of this bean object as required and some
other attributes I don't want to include in the request --> these
attributes should not exist in the generated WSDL.
Can someone tell me how I can annotate this attributes that the needed
behaviour is generated?
Regards,
TMK