A Message-sent handler proposal [message #612045] |
Tue, 23 January 2007 10:24  |
Eclipse User |
|
|
|
Hi,
working with ECF on my application, i need to handle send/receive messages of the shared objects for tracing all the messages that are received and sent from/to all the others shared objects; to handle received messages I can add a IEventProcessor, but I don't find any mechanism to handle the event that my shared object sent a message.
So, i've added this mechanism as an event/listener mechanism: i've a IMessageSendedHandler, and after the getContext().sendMessage(...), I fire the event to all registered listeners.
Can this problem be tackled (this way or any other) in one of the future releases of ECF?
thanks
|
|
|
Re: A Message-sent handler proposal [message #612046 is a reply to message #612045] |
Tue, 23 January 2007 11:49   |
Eclipse User |
|
|
|
Hi Antonio,
antonio wrote:
> Hi,
> working with ECF on my application, i need to handle send/receive messages of the shared objects for tracing all the messages that are received and sent from/to all the others shared objects; to handle received messages I can add a IEventProcessor, but I don't find any mechanism to handle the event that my shared object sent a message.
> So, i've added this mechanism as an event/listener mechanism: i've a IMessageSendedHandler, and after the getContext().sendMessage(...), I fire the event to all registered listeners.
>
>
> Can this problem be tackled (this way or any other) in one of the future releases of ECF?
It could. Just so I'm clear...you are interested in a listener for
*all* shared object messages within a given container?
Note another way to do what you want to do is to override one of the
container classes (TCPClientSOContainer) and override one of the
protected methods for handling shared object messages.
We could also build into the IContainerListener the notification of
shared object messages, and then any registered listeners (via
IContainer.addListener(IContainerListener) would be notified of these
messages (for ISharedObjectContainers anyway).
If you could describe the use case a little further we can jointly
figure out what the right answer is here.
Thanks,
Scott
|
|
|
|
|
|
Re: A Message-sent handler proposal [message #612054 is a reply to message #612053] |
Wed, 31 January 2007 12:42  |
Eclipse User |
|
|
|
Hi Antonio,
Would you mind creating an enhancement request/bug for this?
https://bugs.eclipse.org/bugs/enter_bug.cgi?product=ECF
That way it will be tracked and interest from others can be recorded.
Thanks!
Scott
antonio wrote:
> Hi,
> i think that the second solution is better because for several reasons: it is more flexible for all shared object container types; if there are more processor for these events; in order to separate logic from the container implementation.
>
> thanks :)
|
|
|
Powered by
FUDForum. Page generated in 0.03912 seconds