Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF » (no subject)
(no subject) [message #688089] Thu, 23 June 2011 21:58 Go to next message
Ole Ersoy is currently offline Ole ErsoyFriend
Messages: 205
Registered: July 2009
Senior Member
Hi,

Is there a way to add EAnnotations and automatically have them translated into java code annotations? I see there was some discussion about this here (2007):

http://www.eclipsezone.com/eclipse/forums/t93773.html

TIA,
- Ole
(no subject) [message #688122 is a reply to message #688089] Fri, 24 June 2011 00:44 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33113
Registered: July 2009
Senior Member
No, there's still no support for that.

Ole Ersoy wrote:
> Hi,
>
> Is there a way to add EAnnotations and automatically have them
> translated into java code annotations? I see there was some
> discussion about this here (2007):
>
> http://www.eclipsezone.com/eclipse/forums/t93773.html
>
> TIA,
> - Ole


Ed Merks
Professional Support: https://www.macromodeling.com/
(no subject) [message #688387 is a reply to message #688122] Fri, 24 June 2011 15:40 Go to previous messageGo to next message
Ole Ersoy is currently offline Ole ErsoyFriend
Messages: 205
Registered: July 2009
Senior Member
Dag Nab it - I was hoping integration with JSR 303 would be simple. Anything I can do to help?

On 06/23/2011 07:44 PM, Ed Merks wrote:
> No, there's still no support for that.
>
> Ole Ersoy wrote:
>> Hi,
>>
>> Is there a way to add EAnnotations and automatically have them
>> translated into java code annotations? I see there was some discussion
>> about this here (2007):
>>
>> http://www.eclipsezone.com/eclipse/forums/t93773.html
>>
>> TIA,
>> - Ole
(no subject) [message #688401 is a reply to message #688387] Fri, 24 June 2011 15:54 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33113
Registered: July 2009
Senior Member
Ole,

Have you looked into Teneo?

Alternatively I imagine we could have some special type of EAnnotation
that the generator would use to produce real Java annotations. I've not
given any thought to how one might structure such things to make them
general and flexible...

You can use dynamic templates and take advantage of
Class/getGenFeature.annotations.insert.javajetinc to insert annotations
yourself based on information in your Ecore or GenModel...


Ole Ersoy wrote:
> Dag Nab it - I was hoping integration with JSR 303 would be simple.
> Anything I can do to help?
>
> On 06/23/2011 07:44 PM, Ed Merks wrote:
>> No, there's still no support for that.
>>
>> Ole Ersoy wrote:
>>> Hi,
>>>
>>> Is there a way to add EAnnotations and automatically have them
>>> translated into java code annotations? I see there was some discussion
>>> about this here (2007):
>>>
>>> http://www.eclipsezone.com/eclipse/forums/t93773.html
>>>
>>> TIA,
>>> - Ole
>


Ed Merks
Professional Support: https://www.macromodeling.com/
(no subject) [message #688402 is a reply to message #688401] Fri, 24 June 2011 16:03 Go to previous messageGo to next message
Ole Ersoy is currently offline Ole ErsoyFriend
Messages: 205
Registered: July 2009
Senior Member
Ed,

> Have you looked into Teneo?

I do use Teneo and wanted to give Hibernate Validator a shot at performing my validation work.

> Alternatively I imagine we could have some special type of EAnnotation
> that the generator would use to produce real Java annotations. I've not
> given any thought to how one might structure such things to make them
> general and flexible...

OK - I'll start reviewing some of the history on this.

>
> You can use dynamic templates and take advantage of
> Class/getGenFeature.annotations.insert.javajetinc to insert annotations
> yourself based on information in your Ecore or GenModel...

Ah - That sounds promising. I'll look into as well. Thanks!

- Ole
(no subject) [message #688466 is a reply to message #688402] Fri, 24 June 2011 18:20 Go to previous messageGo to next message
Martin Taal is currently offline Martin TaalFriend
Messages: 5468
Registered: July 2009
Senior Member
Hi Ole,
Depending on how use EMF, the Texo project could also be interesting. It supports also specifying java annotationgs in
EAnnotations, these are placed in the corresponding location in the generated code:
http://wiki.eclipse.org/Texo/Direct_Java_Annotations

You can also easily extend/override the templates:
http://wiki.eclipse.org/Texo/Template_Overriding

and generate an orm:
http://wiki.eclipse.org/Texo/Generate_JPA-ORM_Introduction

and control the code/orm generation through annotations on the model:
http://wiki.eclipse.org/Texo/Code_Generation_Details

gr. Martin

On 06/24/2011 06:03 PM, Ole Ersoy wrote:
> Ed,
>
>> Have you looked into Teneo?
>
> I do use Teneo and wanted to give Hibernate Validator a shot at performing my validation work.
>
>> Alternatively I imagine we could have some special type of EAnnotation
>> that the generator would use to produce real Java annotations. I've not
>> given any thought to how one might structure such things to make them
>> general and flexible...
>
> OK - I'll start reviewing some of the history on this.
>
>>
>> You can use dynamic templates and take advantage of
>> Class/getGenFeature.annotations.insert.javajetinc to insert annotations
>> yourself based on information in your Ecore or GenModel...
>
> Ah - That sounds promising. I'll look into as well. Thanks!
>
> - Ole


--

With Regards, Martin Taal

Springsite/Elver.org
Office: Hardwareweg 4, 3821 BV Amersfoort
Postal: Nassaulaan 7, 3941 EC Doorn
The Netherlands
Cell: +31 (0)6 288 48 943
Tel: +31 (0)84 420 2397
Fax: +31 (0)84 225 9307
Mail: mtaal@springsite.com - mtaal@elver.org
Web: www.springsite.com - www.elver.org
(no subject) [message #688501 is a reply to message #688466] Fri, 24 June 2011 19:59 Go to previous messageGo to next message
Ole Ersoy is currently offline Ole ErsoyFriend
Messages: 205
Registered: July 2009
Senior Member
Hi Martin,

Yeah Yeah - But can it finish my whole project in one click? Just kidding (Although I would not be surprised if someone said "Well more like 3 clicks..."). Texo Rocks!! Thank you for pointing this out,

- Ole



On 06/24/2011 01:20 PM, Martin Taal wrote:
> Hi Ole,
> Depending on how use EMF, the Texo project could also be interesting. It
> supports also specifying java annotationgs in EAnnotations, these are
> placed in the corresponding location in the generated code:
> http://wiki.eclipse.org/Texo/Direct_Java_Annotations
>
> You can also easily extend/override the templates:
> http://wiki.eclipse.org/Texo/Template_Overriding
>
> and generate an orm:
> http://wiki.eclipse.org/Texo/Generate_JPA-ORM_Introduction
>
> and control the code/orm generation through annotations on the model:
> http://wiki.eclipse.org/Texo/Code_Generation_Details
>
> gr. Martin
>
> On 06/24/2011 06:03 PM, Ole Ersoy wrote:
>> Ed,
>>
>>> Have you looked into Teneo?
>>
>> I do use Teneo and wanted to give Hibernate Validator a shot at
>> performing my validation work.
>>
>>> Alternatively I imagine we could have some special type of EAnnotation
>>> that the generator would use to produce real Java annotations. I've not
>>> given any thought to how one might structure such things to make them
>>> general and flexible...
>>
>> OK - I'll start reviewing some of the history on this.
>>
>>>
>>> You can use dynamic templates and take advantage of
>>> Class/getGenFeature.annotations.insert.javajetinc to insert annotations
>>> yourself based on information in your Ecore or GenModel...
>>
>> Ah - That sounds promising. I'll look into as well. Thanks!
>>
>> - Ole
>
>
(no subject) [message #688550 is a reply to message #688501] Fri, 24 June 2011 22:09 Go to previous message
Martin Taal is currently offline Martin TaalFriend
Messages: 5468
Registered: July 2009
Senior Member
Thanks Ole good to hear that it helps!

gr. Martin

On 06/24/2011 09:59 PM, Ole Ersoy wrote:
> Hi Martin,
>
> Yeah Yeah - But can it finish my whole project in one click? Just kidding (Although I would not be surprised if someone
> said "Well more like 3 clicks..."). Texo Rocks!! Thank you for pointing this out,
>
> - Ole
>
>
> On 06/24/2011 01:20 PM, Martin Taal wrote:
>> Hi Ole,
>> Depending on how use EMF, the Texo project could also be interesting. It
>> supports also specifying java annotationgs in EAnnotations, these are
>> placed in the corresponding location in the generated code:
>> http://wiki.eclipse.org/Texo/Direct_Java_Annotations
>>
>> You can also easily extend/override the templates:
>> http://wiki.eclipse.org/Texo/Template_Overriding
>>
>> and generate an orm:
>> http://wiki.eclipse.org/Texo/Generate_JPA-ORM_Introduction
>>
>> and control the code/orm generation through annotations on the model:
>> http://wiki.eclipse.org/Texo/Code_Generation_Details
>>
>> gr. Martin
>>
>> On 06/24/2011 06:03 PM, Ole Ersoy wrote:
>>> Ed,
>>>
>>>> Have you looked into Teneo?
>>>
>>> I do use Teneo and wanted to give Hibernate Validator a shot at
>>> performing my validation work.
>>>
>>>> Alternatively I imagine we could have some special type of EAnnotation
>>>> that the generator would use to produce real Java annotations. I've not
>>>> given any thought to how one might structure such things to make them
>>>> general and flexible...
>>>
>>> OK - I'll start reviewing some of the history on this.
>>>
>>>>
>>>> You can use dynamic templates and take advantage of
>>>> Class/getGenFeature.annotations.insert.javajetinc to insert annotations
>>>> yourself based on information in your Ecore or GenModel...
>>>
>>> Ah - That sounds promising. I'll look into as well. Thanks!
>>>
>>> - Ole
>>
>>
>


--

With Regards, Martin Taal

Springsite/Elver.org
Office: Hardwareweg 4, 3821 BV Amersfoort
Postal: Nassaulaan 7, 3941 EC Doorn
The Netherlands
Cell: +31 (0)6 288 48 943
Tel: +31 (0)84 420 2397
Fax: +31 (0)84 225 9307
Mail: mtaal@springsite.com - mtaal@elver.org
Web: www.springsite.com - www.elver.org
Previous Topic:OPTION_ESCAPE_USING_CDATA
Next Topic:[Hibernate] HQL statement for one-to-many
Goto Forum:
  


Current Time: Thu Mar 28 08:32:58 GMT 2024

Powered by FUDForum. Page generated in 0.05574 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top