Exemplo n.º 1
0
 void sendClientEvent(ClientEvent event) {
   final EventService eventService = nodeEngine.getEventService();
   final Collection<EventRegistration> regs =
       eventService.getRegistrations(SERVICE_NAME, SERVICE_NAME);
   String uuid = event.getUuid();
   eventService.publishEvent(SERVICE_NAME, regs, event, uuid.hashCode());
 }
Exemplo n.º 2
0
 @Override
 public void dispatchEvent(ClientEvent event, ClientListener listener) {
   if (event.getEventType() == ClientEventType.CONNECTED) {
     listener.clientConnected(event);
   } else {
     listener.clientDisconnected(event);
   }
 }