Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Oomph » Where are the supported annotations documented?
Where are the supported annotations documented? [message #1700565] Fri, 03 July 2015 18:53 Go to next message
Silvestre Martins is currently offline Silvestre MartinsFriend
Messages: 84
Registered: July 2009
Member
When configuring tasks it becomes very easy and intuitive because it uses the EMF model. So the context menu only offers what makes sense in that context.
But the same doesn't happen with the Annotations. I would expect that there is some wiki or similar where I can find all supported annotation for all tasks. However I followed all links from the wiki and I didn't find anything.

Does anyone know where I can find this information?
Thanks in advance.
Re: Where are the supported annotations documented? [message #1700567 is a reply to message #1700565] Fri, 03 July 2015 19:28 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33141
Registered: July 2009
Senior Member
Silvestre,

Comments below.


On 03/07/2015 8:53 PM, Silvestre Martins wrote:
> When configuring tasks it becomes very easy and intuitive because it
> uses the EMF model. So the context menu only offers what makes sense
> in that context.
Yes, you can only create syntactically valid instances...
> But the same doesn't happen with the Annotations.
Indeed. But we ought to make that smarter with specializations in the
child creation of the item providers...
> I would expect that there is some wiki or similar where I can find all
> supported annotation for all tasks.
Indeed, and a few months ago I did start working on documentation (along
with a nice generator to make it cool and maintainable)... But then all
the release pressures took priority, and now some personal issues take
priority...
> However I followed all links from the wiki and I didn't find anything.
No, because it just doesn't exist.
>
> Does anyone know where I can find this information?
No, it's basically completely undocumented at this point, so only
examples of setups serve as a guide, or worse yet, looking at code...
Sorry, it will be a while yet...
> Thanks in advance.


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: Where are the supported annotations documented? [message #1700569 is a reply to message #1700567] Fri, 03 July 2015 19:58 Go to previous messageGo to next message
Silvestre Martins is currently offline Silvestre MartinsFriend
Messages: 84
Registered: July 2009
Member
Ok, I see.

I wonder if is there some way I can at least know what annotations exist so I can know where to look in the code.

For instance, if I checkout the oomph source code, can I look for all classes implementing a specific interface, or can I look for references to some method?

Thanks.


Ed Merks wrote on Fri, 03 July 2015 15:28
Silvestre,

Comments below.


On 03/07/2015 8:53 PM, Silvestre Martins wrote:
> When configuring tasks it becomes very easy and intuitive because it
> uses the EMF model. So the context menu only offers what makes sense
> in that context.
Yes, you can only create syntactically valid instances...
> But the same doesn't happen with the Annotations.
Indeed. But we ought to make that smarter with specializations in the
child creation of the item providers...
> I would expect that there is some wiki or similar where I can find all
> supported annotation for all tasks.
Indeed, and a few months ago I did start working on documentation (along
with a nice generator to make it cool and maintainable)... But then all
the release pressures took priority, and now some personal issues take
priority...
> However I followed all links from the wiki and I didn't find anything.
No, because it just doesn't exist.
>
> Does anyone know where I can find this information?
No, it's basically completely undocumented at this point, so only
examples of setups serve as a guide, or worse yet, looking at code...
Sorry, it will be a while yet...
> Thanks in advance.

Re: Where are the supported annotations documented? [message #1700581 is a reply to message #1700569] Sat, 04 July 2015 06:54 Go to previous messageGo to next message
Eike Stepper is currently offline Eike StepperFriend
Messages: 6682
Registered: July 2009
Senior Member
Am 03.07.2015 um 21:58 schrieb Silvestre Martins:
> Ok, I see.
>
> I wonder if is there some way I can at least know what annotations exist so I can know where to look in the code.
>
> For instance, if I checkout the oomph source code, can I look for all classes implementing a specific interface, or
> can I look for references to some method?
There are some interfaces that declare annotation constants:

org.eclipse.oomph.base.BaseAnnotationConstants
org.eclipse.oomph.setup.AnnotationConstants
org.eclipse.oomph.setup.EAnnotationConstants

Other annotations are declared directly in the classes that exclusively use them:

org.eclipse.oomph.targlets.internal.core.listeners.PomModulesUpdater
org.eclipse.oomph.targlets.internal.core.listeners.PomArtifactUpdater
org.eclipse.oomph.targlets.internal.core.listeners.TargetDefinitionGenerator

Another way to find the usage of annotations is the Call Hierarchy of these two methods:

org.eclipse.oomph.base.ModelElement.getAnnotations()
org.eclipse.oomph.base.ModelElement.getAnnotation(String)

I hope that helps. If you find the time you could start a new wiki page to collect your findings ;-)

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper



>
> Thanks.
>
>
> Ed Merks wrote on Fri, 03 July 2015 15:28
>> Silvestre,
>>
>> Comments below.
>>
>>
>> On 03/07/2015 8:53 PM, Silvestre Martins wrote:
>> > When configuring tasks it becomes very easy and intuitive because it > uses the EMF model. So the context menu only
>> offers what makes sense > in that context.
>> Yes, you can only create syntactically valid instances...
>> > But the same doesn't happen with the Annotations. Indeed. But we ought to make that smarter with specializations in
>> the child creation of the item providers...
>> > I would expect that there is some wiki or similar where I can find all > supported annotation for all tasks.
>> Indeed, and a few months ago I did start working on documentation (along with a nice generator to make it cool and
>> maintainable)... But then all the release pressures took priority, and now some personal issues take priority...
>> > However I followed all links from the wiki and I didn't find anything.
>> No, because it just doesn't exist.
>> >
>> > Does anyone know where I can find this information?
>> No, it's basically completely undocumented at this point, so only examples of setups serve as a guide, or worse yet,
>> looking at code... Sorry, it will be a while yet...
>> > Thanks in advance.
>
>


Re: Where are the supported annotations documented? [message #1700594 is a reply to message #1700581] Sat, 04 July 2015 09:29 Go to previous messageGo to next message
Silvestre Martins is currently offline Silvestre MartinsFriend
Messages: 84
Registered: July 2009
Member
Ok, I'll try.
Thanks.
Re: Where are the supported annotations documented? [message #1700681 is a reply to message #1700581] Mon, 06 July 2015 12:42 Go to previous messageGo to next message
Christian Damus is currently offline Christian DamusFriend
Messages: 1270
Registered: July 2009
Location: Canada
Senior Member

Hi, Eike,

I have to ask: how is it decided whether some particle of information
is modeled explicitly in the pertinent setup Ecore model or whether it
is modeled in more ad hoc fashion as an annotation?

Also, annotations could be ever so much helpful if I could define my
own and plug in (via an extension point or something) an annotation
processor. Preferably with the option to process before the main loop
that interprets/expands the setup model. I have a use case for an
annotation that would calculate variable values so that I don't have to
repeat them in every one of three streams for dozens of
sub-sub-projects.

Cheers,

Christian


On 2015-07-04 06:54:40 +0000, Eike Stepper said:

> Am 03.07.2015 um 21:58 schrieb Silvestre Martins:
>> Ok, I see.
>>
>> I wonder if is there some way I can at least know what annotations
>> exist so I can know where to look in the code.
>>
>> For instance, if I checkout the oomph source code, can I look for all
>> classes implementing a specific interface, or can I look for references
>> to some method?
> There are some interfaces that declare annotation constants:
>
> org.eclipse.oomph.base.BaseAnnotationConstants
> org.eclipse.oomph.setup.AnnotationConstants
> org.eclipse.oomph.setup.EAnnotationConstants
>
> Other annotations are declared directly in the classes that exclusively
> use them:
>
> org.eclipse.oomph.targlets.internal.core.listeners.PomModulesUpdater
> org.eclipse.oomph.targlets.internal.core.listeners.PomArtifactUpdater
> org.eclipse.oomph.targlets.internal.core.listeners.TargetDefinitionGenerator
>
> Another way to find the usage of annotations is the Call Hierarchy of
> these two methods:
>
> org.eclipse.oomph.base.ModelElement.getAnnotations()
> org.eclipse.oomph.base.ModelElement.getAnnotation(String)
>
> I hope that helps. If you find the time you could start a new wiki page
> to collect your findings ;-)
>
> Cheers
> /Eike
>
> ----
> http://www.esc-net.de
> http://thegordian.blogspot.com
> http://twitter.com/eikestepper
>
>
>
>>
>> Thanks.
>>
>>
>> Ed Merks wrote on Fri, 03 July 2015 15:28
>>> Silvestre,
>>>
>>> Comments below.
>>>
>>>
>>> On 03/07/2015 8:53 PM, Silvestre Martins wrote:
>>>> When configuring tasks it becomes very easy and intuitive because it >
>>>> uses the EMF model. So the context menu only
>>> offers what makes sense > in that context.
>>> Yes, you can only create syntactically valid instances...
>>>> But the same doesn't happen with the Annotations. Indeed. But we ought
>>>> to make that smarter with specializations in
>>> the child creation of the item providers...
>>>> I would expect that there is some wiki or similar where I can find all
>>>> > supported annotation for all tasks.
>>> Indeed, and a few months ago I did start working on documentation
>>> (along with a nice generator to make it cool and maintainable)... But
>>> then all the release pressures took priority, and now some personal
>>> issues take priority...
>>>> However I followed all links from the wiki and I didn't find anything.
>>> No, because it just doesn't exist.
>>>>
>>>> Does anyone know where I can find this information?
>>> No, it's basically completely undocumented at this point, so only
>>> examples of setups serve as a guide, or worse yet, looking at code...
>>> Sorry, it will be a while yet...
>>>> Thanks in advance.
Re: Where are the supported annotations documented? [message #1700684 is a reply to message #1700681] Mon, 06 July 2015 13:05 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 6682
Registered: July 2009
Senior Member
Am 06.07.2015 um 14:42 schrieb Christian W. Damus:
> Hi, Eike,
>
> I have to ask: how is it decided whether some particle of information is modeled explicitly in the pertinent setup
> Ecore model or whether it is modeled in more ad hoc fashion as an annotation?
That has been decided by the team on a case by case basis. Maybe Ed remembers some general rules ;-)

> Also, annotations could be ever so much helpful if I could define my own and plug in (via an extension point or
> something) an annotation processor. Preferably with the option to process before the main loop that
> interprets/expands the setup model. I have a use case for an annotation that would calculate variable values so that
> I don't have to repeat them in every one of three streams for dozens of sub-sub-projects.
The more general facility would probably "just" a pluggable model preprocessor mechanism. On the one hand that sounds
very powerful and interesting, on the other hand it sounds pretty scary if, for example, an arbitrary plugin can hook in
a preprocessor that sets disabled=true on all tasks, always. I'm not sure how we could control the ultimate force once
we've passed it to the public.

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper



>
> Cheers,
>
> Christian
>
>
> On 2015-07-04 06:54:40 +0000, Eike Stepper said:
>
>> Am 03.07.2015 um 21:58 schrieb Silvestre Martins:
>>> Ok, I see.
>>>
>>> I wonder if is there some way I can at least know what annotations exist so I can know where to look in the code.
>>>
>>> For instance, if I checkout the oomph source code, can I look for all classes implementing a specific interface, or
>>> can I look for references to some method?
>> There are some interfaces that declare annotation constants:
>>
>> org.eclipse.oomph.base.BaseAnnotationConstants
>> org.eclipse.oomph.setup.AnnotationConstants
>> org.eclipse.oomph.setup.EAnnotationConstants
>>
>> Other annotations are declared directly in the classes that exclusively use them:
>>
>> org.eclipse.oomph.targlets.internal.core.listeners.PomModulesUpdater
>> org.eclipse.oomph.targlets.internal.core.listeners.PomArtifactUpdater
>> org.eclipse.oomph.targlets.internal.core.listeners.TargetDefinitionGenerator
>>
>> Another way to find the usage of annotations is the Call Hierarchy of these two methods:
>>
>> org.eclipse.oomph.base.ModelElement.getAnnotations()
>> org.eclipse.oomph.base.ModelElement.getAnnotation(String)
>>
>> I hope that helps. If you find the time you could start a new wiki page to collect your findings ;-)
>>
>> Cheers
>> /Eike
>>
>> ----
>> http://www.esc-net.de
>> http://thegordian.blogspot.com
>> http://twitter.com/eikestepper
>>
>>
>>
>>>
>>> Thanks.
>>>
>>>
>>> Ed Merks wrote on Fri, 03 July 2015 15:28
>>>> Silvestre,
>>>>
>>>> Comments below.
>>>>
>>>>
>>>> On 03/07/2015 8:53 PM, Silvestre Martins wrote:
>>>>> When configuring tasks it becomes very easy and intuitive because it > uses the EMF model. So the context menu only
>>>> offers what makes sense > in that context.
>>>> Yes, you can only create syntactically valid instances...
>>>>> But the same doesn't happen with the Annotations. Indeed. But we ought to make that smarter with specializations in
>>>> the child creation of the item providers...
>>>>> I would expect that there is some wiki or similar where I can find all > supported annotation for all tasks.
>>>> Indeed, and a few months ago I did start working on documentation (along with a nice generator to make it cool and
>>>> maintainable)... But then all the release pressures took priority, and now some personal issues take priority...
>>>>> However I followed all links from the wiki and I didn't find anything.
>>>> No, because it just doesn't exist.
>>>>>
>>>>> Does anyone know where I can find this information?
>>>> No, it's basically completely undocumented at this point, so only examples of setups serve as a guide, or worse
>>>> yet, looking at code... Sorry, it will be a while yet...
>>>>> Thanks in advance.
>
>


Previous Topic:Targlet cannot be resolved
Next Topic:Passing VM args from the self extracting archive to eclipse-inst.exe
Goto Forum:
  


Current Time: Thu Apr 25 22:21:59 GMT 2024

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

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

Back to the top