Skip to content

Instantly share code, notes, and snippets.

@seyedsahil
Created March 8, 2020 17:58
Show Gist options
  • Save seyedsahil/50e7d4bfcdcf57bde1d10e5a2972077a to your computer and use it in GitHub Desktop.
Save seyedsahil/50e7d4bfcdcf57bde1d10e5a2972077a to your computer and use it in GitHub Desktop.
Sending the Message
// Inside MessageListener.update(Observable , Object )
public void update(Observable messageQueue, Object parameters) {
if (messageQueue instanceof MessageQueue) {
MessagingService messagingService = MessagingService.getInstance();
messagingService.send(userId, messageQueue.getMessage());
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment