Using CDORemoteSessionManager [message #1420643] |
Wed, 10 September 2014 05:03  |
Eclipse User |
|
|
|
I want to use CDORemoteSessionManager to send message from one session to another.
I can send the message to all RemoteSessions. But I do not know how to receive those sent messages. I looked into the javac doc of CDORemoteSessionManager. But still I do not understand how to receive the sent message.
I need to send an xml file from one session to other remote sessions. Is it possible to do this using CDORemoteSessionManager?
The method I use to send the message is given below:
private void sendMessage() {
InternalCDORemoteSessionManager remoteSessionManager = new CDORemoteSessionManagerImpl();
remoteSessionManager.setLocalSession(this.getSession());
remoteSessionManager.setForceSubscription(true);
remoteSessionManager.activate();
CDORemoteSession[] recipients=remoteSessionManager.getRemoteSessions();
for(CDORemoteSession session:recipients)
{
remoteSessionManager.handleRemoteSessionSubscribed(session.getSessionID(), true);
}
CDORemoteSessionMessage message = new CDORemoteSessionMessage("Fist Message");
remoteSessionManager.sendMessage(message, recipients);
}
thanks,
Uma Shankar
[Updated on: Wed, 10 September 2014 05:07] by Moderator
|
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.04359 seconds