Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF » Write unique package registry with unique extension point?
Write unique package registry with unique extension point? [message #426770] Tue, 20 January 2009 10:00 Go to next message
Zoltan Balogh is currently offline Zoltan BaloghFriend
Messages: 9
Registered: July 2009
Junior Member
Hi,

My goal is to mark somehow certain EMF packages in the workspace. In
case of EMF’s package registry mechanism, I can reach all the packages
that are registered to it. I would like to reach somehow only the marked
ones.

I think a simple solution can be to write my own registry with an
extension point, and the models that need to be marked have to be extend
this extension point.

My only problem that this solution is totally independent form the EMF’s
implementation. I would like to ask that is there any better way to
reach my goal?

Thanks for the answers!
Re: Write unique package registry with unique extension point? [message #426775 is a reply to message #426770] Tue, 20 January 2009 11:41 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33140
Registered: July 2009
Senior Member
This is a multi-part message in MIME format.
--------------050209030509020300010804
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit

Zoltan,

Comments below.

Zoltan Balogh wrote:
> Hi,
>
> My goal is to mark somehow certain EMF packages in the workspace. In
> case of EMF’s package registry mechanism, I can reach all the packages
> that are registered to it. I would like to reach somehow only the
> marked ones.
It sounds slightly like

https://bugs.eclipse.org/bugs/show_bug.cgi?id=220218

Note that EPackage.Registry.INSTANCE contains packages registered in the
running IDE itself, but knows nothing about what's in the workspace.
>
> I think a simple solution can be to write my own registry with an
> extension point, and the models that need to be marked have to be
> extend this extension point.
To process extension point stuff in the workspace itself you'd need to
use the PDE APIs. That's what the above bugzilla is about. (I can't
believe a whole year has gone by without having time for it.)
>
> My only problem that this solution is totally independent form the
> EMF’s implementation. I would like to ask that is there any better way
> to reach my goal?
I could imagine that you might put an EAnnotation on the package, and
then index (crawl) the workspace looking for *.ecore files with an
EPackage with your annotation. The extension point thing is reasonable
as well, and involves using the PDE to crawl all the plugin.xml files.
>
> Thanks for the answers!

--------------050209030509020300010804
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: 8bit

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=UTF-8" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Zoltan,<br>
<br>
Comments below.<br>
<br>
Zoltan Balogh wrote:
<blockquote cite="mid:gl47c7$cco$1@build.eclipse.org" type="cite">Hi,
<br>
<br>
My goal is to mark somehow certain EMF packages in the workspace. In
case of EMF’s package registry mechanism, I can reach all the packages
that are registered to it. I would like to reach somehow only the
marked ones.
<br>
</blockquote>
It sounds slightly like<br>
<blockquote><a
href="https://bugs.eclipse.org/bugs/show_bug.cgi?id=220218">https://bugs.eclipse.org/bugs/show_bug.cgi?id=220218</a><br>
</blockquote>
Note that EPackage.Registry.INSTANCE contains packages registered in
the running IDE itself, but knows nothing about what's in the workspace.<br>
<blockquote cite="mid:gl47c7$cco$1@build.eclipse.org" type="cite"><br>
I think a simple solution can be to write my own registry with an
extension point, and the models that need to be marked have to be
extend this extension point.
<br>
</blockquote>
To process extension point stuff in the workspace itself you'd need to
use the PDE APIs.  That's what the above bugzilla is about. (I can't
believe a whole year has gone by without having time for it.)<br>
<blockquote cite="mid:gl47c7$cco$1@build.eclipse.org" type="cite"><br>
My only problem that this solution is totally independent form the
EMF’s implementation. I would like to ask that is there any better way
to reach my goal?
<br>
</blockquote>
I could imagine that you might put an EAnnotation on the package, and
then index (crawl) the workspace looking for *.ecore files with an
EPackage with your annotation.  The extension point thing is reasonable
as well,  and involves using the PDE to crawl all the plugin.xml files.<br>
<blockquote cite="mid:gl47c7$cco$1@build.eclipse.org" type="cite"><br>
Thanks for the answers!
<br>
</blockquote>
</body>
</html>

--------------050209030509020300010804--


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: Write unique package registry with unique extension point? [message #426783 is a reply to message #426775] Tue, 20 January 2009 13:30 Go to previous messageGo to next message
Zoltan Balogh is currently offline Zoltan BaloghFriend
Messages: 9
Registered: July 2009
Junior Member
Sorry, but the "workspace" was very misleading. I should have to write
"running IDE" instead. So I don’t have to search in the actual
workspace. Otherwise it seems to me that I should write my own registry,
just like the general EMF package registry. In this case the packages
that need to be marked, only has to extend my extension point and there
is no need for additional extension (e.g. adding addition EAnnotation
for packages).

Ed Merks írta:
> Zoltan,
>
> Comments below.
>
> Zoltan Balogh wrote:
>> Hi,
>>
>> My goal is to mark somehow certain EMF packages in the workspace. In
>> case of EMF’s package registry mechanism, I can reach all the packages
>> that are registered to it. I would like to reach somehow only the
>> marked ones.
> It sounds slightly like
>
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=220218
>
> Note that EPackage.Registry.INSTANCE contains packages registered in the
> running IDE itself, but knows nothing about what's in the workspace.
>>
>> I think a simple solution can be to write my own registry with an
>> extension point, and the models that need to be marked have to be
>> extend this extension point.
> To process extension point stuff in the workspace itself you'd need to
> use the PDE APIs. That's what the above bugzilla is about. (I can't
> believe a whole year has gone by without having time for it.)
>>
>> My only problem that this solution is totally independent form the
>> EMF’s implementation. I would like to ask that is there any better way
>> to reach my goal?
> I could imagine that you might put an EAnnotation on the package, and
> then index (crawl) the workspace looking for *.ecore files with an
> EPackage with your annotation. The extension point thing is reasonable
> as well, and involves using the PDE to crawl all the plugin.xml files.
>>
>> Thanks for the answers!
Re: Write unique package registry with unique extension point? [message #426786 is a reply to message #426783] Tue, 20 January 2009 15:12 Go to previous message
Ed Merks is currently offline Ed MerksFriend
Messages: 33140
Registered: July 2009
Senior Member
Zoltan,

Yes, in that case, and extension point is ideal.


Zoltan Balogh wrote:
> Sorry, but the "workspace" was very misleading. I should have to write
> "running IDE" instead. So I don’t have to search in the actual
> workspace. Otherwise it seems to me that I should write my own
> registry, just like the general EMF package registry. In this case the
> packages that need to be marked, only has to extend my extension point
> and there is no need for additional extension (e.g. adding addition
> EAnnotation for packages).
>
> Ed Merks írta:
>> Zoltan,
>>
>> Comments below.
>>
>> Zoltan Balogh wrote:
>>> Hi,
>>>
>>> My goal is to mark somehow certain EMF packages in the workspace. In
>>> case of EMF’s package registry mechanism, I can reach all the
>>> packages that are registered to it. I would like to reach somehow
>>> only the marked ones.
>> It sounds slightly like
>>
>> https://bugs.eclipse.org/bugs/show_bug.cgi?id=220218
>>
>> Note that EPackage.Registry.INSTANCE contains packages registered in
>> the running IDE itself, but knows nothing about what's in the workspace.
>>>
>>> I think a simple solution can be to write my own registry with an
>>> extension point, and the models that need to be marked have to be
>>> extend this extension point.
>> To process extension point stuff in the workspace itself you'd need
>> to use the PDE APIs. That's what the above bugzilla is about. (I
>> can't believe a whole year has gone by without having time for it.)
>>>
>>> My only problem that this solution is totally independent form the
>>> EMF’s implementation. I would like to ask that is there any better
>>> way to reach my goal?
>> I could imagine that you might put an EAnnotation on the package, and
>> then index (crawl) the workspace looking for *.ecore files with an
>> EPackage with your annotation. The extension point thing is
>> reasonable as well, and involves using the PDE to crawl all the
>> plugin.xml files.
>>>
>>> Thanks for the answers!


Ed Merks
Professional Support: https://www.macromodeling.com/
Previous Topic:AnySimpleType
Next Topic:validation in case of other constraints
Goto Forum:
  


Current Time: Thu Apr 25 12:20:32 GMT 2024

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

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

Back to the top