|
Re: The trigger when the node is moved [message #1775864 is a reply to message #1775794] |
Tue, 07 November 2017 10:56 |
|
Hi,
it really depends on what the "action" you want to call does. If your action needs to make any change to any of the EMF models inside the session, it must be a pre-commit listener (implemented as a command returned from transactionAboutToCommit). Otherwise (i.e. it will only impact some UI or non-EMF data structure), it's better to use a post-commit listener (implemented in resourceSetChanged as in your example).
Note the Sirius already has several pre and post-commit listeners registered, so depending on what you want to do you may need to make sure yours are invoked before or after Sirius's own. See Session.getEventBroker() which exposes an API to better control the ordering of pre-commit listeners (at least the ones that use it).
Regards,
Pierre-Charles David - Obeo
Need training or professional services for Sirius?
http://www.obeodesigner.com/sirius
|
|
|
|
Powered by
FUDForum. Page generated in 0.04596 seconds