Register adapters [message #723831] |
Fri, 09 September 2011 11:34  |
Eclipse User |
|
|
|
Hello,
I would like to create a plugin in which I have some EContentAdapters which listen changes on my model (the metamodel plugin is an other one).
I can't understand how to do it.
What I would like to do is create a plugin project which depends on my metamodel project.
And develop my EContentAdapter and make it listen any models conforming my metamodel.
So how to achieve the last part (i.e make it listen any models conforming my metamodel)?
Best regards,
Xavier
|
|
|
|
|
|
Re: Register adapters [message #724064 is a reply to message #724015] |
Sat, 10 September 2011 11:33  |
Eclipse User |
|
|
|
Xavier,
An EContentAdapter is maybe appropriate for that. You can add it to the
resource set's eAdapters list and it will listen to every resource and
every object within that resource. There's no extension point for
doing this. You'd have to define one yourself specific to your editor.
On 10/09/2011 3:18 AM, Xavier Seignard wrote:
> Ed,
> Thanks for your answer. Maybe EContentAdapter is not the right solution.
>
> The problem I want to solve is the following :
> - I have a metamodel, metamodel.edit and two editors plugins
> - I want to create a new plugin which will listen changes to any model
> conforming to my metamodel and launch specific actions. So when this
> plugin is loaded, some behavior is added to my metamodel.
>
> So what would be the steps to achieve that (what kind of adapter,
> adapter factory, how to register the adapter, which extension point I
> need to declare)?
>
> Thanks for your future advices,
>
> Best regards,
>
> Xavier
|
|
|
Powered by
FUDForum. Page generated in 0.06044 seconds