JAXB : to generate hashcode(), equals() and toString() methods ?

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

JAXB : to generate hashcode(), equals() and toString() methods ?

Olivier Vincent

Hi,

 

Will it be possible to generate hashcode(), equals() and toString() methods with a next version of JAXB ? And if so, is it planned in a roadmap ?

Or should we always use the JAXB2 Basics Plugin ?

 

Because, this plugin is used by many people and, I think, is very interesting for the JAXB project.

 

Thanks in advance,

 

Best Regards,

 

 

Olivier Vincent

cid:image001.gif@01C93387.B2AD1960

Afficher l'image d'origine  Site du Hainaut    :    Rue d'Ath,    33A,             7900     Leuze-en-Hainaut

http://t0.gstatic.com/images?q=tbn:shOUazya3UTGpM:http://www.sciage-carottage-normandie.fr/img/logo_tel.jpg+32(0)84/31 13 31  http://t3.gstatic.com/images?q=tbn:vPdPV38d_jdziM:http://www.sciage-carottage-normandie.fr/img/logo_fax.jpg+32(0)69/56 05 19  [hidden email][hidden email]

 

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: JAXB : to generate hashcode(), equals() and toString() methods ?

Przemysław Bielicki
Hi Olivier,

why don't you use @EqualsAndHashCode and @ToString annotations from lombok (http://projectlombok.org/) ?

I don't think it's JAXB's responsibility to generate these methods.

I hope it helps.

Cheers,
Przemyslaw


On Tue, Nov 5, 2013 at 11:34 AM, Olivier Vincent <[hidden email]> wrote:

Hi,

 

Will it be possible to generate hashcode(), equals() and toString() methods with a next version of JAXB ? And if so, is it planned in a roadmap ?

Or should we always use the JAXB2 Basics Plugin ?

 

Because, this plugin is used by many people and, I think, is very interesting for the JAXB project.

 

Thanks in advance,

 

Best Regards,

 

 

Olivier Vincent

cid:image001.gif@01C93387.B2AD1960

Afficher l'image d'origine  Site du Hainaut    :    Rue d'Ath,    33A,             7900     Leuze-en-Hainaut

http://t0.gstatic.com/images?q=tbn:shOUazya3UTGpM:http://www.sciage-carottage-normandie.fr/img/logo_tel.jpg<a href="tel:%2B32%280%2984%2F31%2013%2031" value="+3284311331" target="_blank">+32(0)84/31 13 31  http://t3.gstatic.com/images?q=tbn:vPdPV38d_jdziM:http://www.sciage-carottage-normandie.fr/img/logo_fax.jpg<a href="tel:%2B32%280%2969%2F56%2005%2019" value="+3269560519" target="_blank">+32(0)69/56 05 19  [hidden email][hidden email]

 


Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

RE: JAXB : to generate hashcode(), equals() and toString() methods ?

Gary Gregory
In reply to this post by Olivier Vincent
But you cannot use lombok on an XML Schema...

Gary


-------- Original message --------
From: Przemysław Bielicki
Date:11/05/2013 05:56 (GMT-05:00)
To: [hidden email]
Subject: Re: JAXB : to generate hashcode(), equals() and toString() methods ?

Hi Olivier,

why don't you use @EqualsAndHashCode and @ToString annotations from lombok (http://projectlombok.org/) ?

I don't think it's JAXB's responsibility to generate these methods.

I hope it helps.

Cheers,
Przemyslaw


On Tue, Nov 5, 2013 at 11:34 AM, Olivier Vincent <[hidden email]<mailto:[hidden email]>> wrote:
Hi,

Will it be possible to generate hashcode(), equals() and toString() methods with a next version of JAXB ? And if so, is it planned in a roadmap ?
Or should we always use the JAXB2 Basics Plugin ?

Because, this plugin is used by many people and, I think, is very interesting for the JAXB project.

Thanks in advance,

Best Regards,


Olivier Vincent
[cid:image001.gif@01C93387.B2AD1960]<http://www.stesud.com/>
[Afficher l'image d'origine]<http://fr-be.mappy.com/map#d=Rue+Andr%C3%A9+Feher,+6900,+Marche-en-Famenne,+R%C3%A9gion+Wallonne,+Belgique>  Site du Hainaut    :    Rue d'Ath,    33A,             7900     Leuze-en-Hainaut
[http://t0.gstatic.com/images?q=tbn:shOUazya3UTGpM:http://www.sciage-carottage-normandie.fr/img/logo_tel.jpg]+32(0)84/31 13 31<tel:%2B32%280%2984%2F31%2013%2031>  [http://t3.gstatic.com/images?q=tbn:vPdPV38d_jdziM:http://www.sciage-carottage-normandie.fr/img/logo_fax.jpg] +32(0)69/56 05 19<tel:%2B32%280%2969%2F56%2005%2019>  [Afficher l'image d'origine] <mailto:[hidden email]> [hidden email]<mailto:[hidden email]>



image001.gif (2K) Download Attachment
image002.jpg (736 bytes) Download Attachment
image003.jpg (630 bytes) Download Attachment
image004.jpg (638 bytes) Download Attachment
image005.jpg (990 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: JAXB : to generate hashcode(), equals() and toString() methods ?

Przemysław Bielicki
So, the question was about XJC instead of JAXB :) That's correct - Lombok won't help here.

Cheers,
Przemyslaw


On Tue, Nov 5, 2013 at 12:52 PM, Gary Gregory <[hidden email]> wrote:
But you cannot use lombok on an XML Schema...

Gary


-------- Original message --------
From: Przemysław Bielicki
Date:11/05/2013 05:56 (GMT-05:00)
To: [hidden email]
Subject: Re: JAXB : to generate hashcode(), equals() and toString() methods ?

Hi Olivier,

why don't you use @EqualsAndHashCode and @ToString annotations from lombok (http://projectlombok.org/) ?

I don't think it's JAXB's responsibility to generate these methods.

I hope it helps.

Cheers,
Przemyslaw


On Tue, Nov 5, 2013 at 11:34 AM, Olivier Vincent <[hidden email]<mailto:[hidden email]>> wrote:
Hi,

Will it be possible to generate hashcode(), equals() and toString() methods with a next version of JAXB ? And if so, is it planned in a roadmap ?
Or should we always use the JAXB2 Basics Plugin ?

Because, this plugin is used by many people and, I think, is very interesting for the JAXB project.

Thanks in advance,

Best Regards,


Olivier Vincent
[cid:image001.gif@01C93387.B2AD1960]<http://www.stesud.com/>
[Afficher l'image d'origine]<http://fr-be.mappy.com/map#d=Rue+Andr%C3%A9+Feher,+6900,+Marche-en-Famenne,+R%C3%A9gion+Wallonne,+Belgique>  Site du Hainaut    :    Rue d'Ath,    33A,             7900     Leuze-en-Hainaut
[http://t0.gstatic.com/images?q=tbn:shOUazya3UTGpM:http://www.sciage-carottage-normandie.fr/img/logo_tel.jpg]+32(0)84/31 13 31<tel:%2B32%280%2984%2F31%2013%2031>  [http://t3.gstatic.com/images?q=tbn:vPdPV38d_jdziM:http://www.sciage-carottage-normandie.fr/img/logo_fax.jpg] <a href="tel:%2B32%280%2969%2F56%2005%2019" value="+3269560519">+32(0)69/56 05 19<tel:%2B32%280%2969%2F56%2005%2019>  [Afficher l'image d'origine] <mailto:[hidden email]> [hidden email]<mailto:[hidden email]>



Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: JAXB : to generate hashcode(), equals() and toString() methods ?

Iaroslav Savytskyi
In reply to this post by Olivier Vincent
Hi, Olivier,

I completely agree that such functionality should be enabled from scratch.  Unfortunately we have more critical things to implement. And, as you mentioned, for those who need these methods plugins are available.


Best regards,
Iaroslav

On 5 Nov 2013, at 11:34, Olivier Vincent <[hidden email]> wrote:

> Hi,
>  
> Will it be possible to generate hashcode(), equals() and toString() methods with a next version of JAXB ? And if so, is it planned in a roadmap ?
> Or should we always use the JAXB2 Basics Plugin ?
>  
> Because, this plugin is used by many people and, I think, is very interesting for the JAXB project.
>  
> Thanks in advance,
>  
> Best Regards,
>  
>  
> Olivier Vincent
> <image001.gif>
> <image002.jpg>  Site du Hainaut    :    Rue d'Ath,    33A,             7900     Leuze-en-Hainaut
> <image003.jpg>+32(0)84/31 13 31  <image004.jpg>+32(0)69/56 05 19  <image005.jpg>[hidden email]

Loading...