Exemplo n.º 1
0
 public synchronized void bindConnectionNode(OteServerJmsNodeProvider connectionNode) {
   this.connecitonNode = connectionNode;
   connecitonNode.getConnectionNode().subscribe(BridgeMessages.BYTE_MESSAGE, this);
   for (Event event : eventQueue) {
     sendEvent(event);
   }
   eventQueue.clear();
 }
Exemplo n.º 2
0
 private void sendEvent(Event event) {
   OteEventMessage message = OteEventMessageUtil.getOteEventMessage(event);
   if (message != null) {
     try {
       UUID id = OteEventMessageUtil.getUUID(message);
       if (!id.equals(MYID)) {
         OteEventMessageUtil.setUUID(message, MYID);
         connecitonNode.getConnectionNode().send(BridgeMessages.BYTE_MESSAGE, message.getData());
       }
     } catch (OseeCoreException e) {
       e.printStackTrace();
     }
   }
 }
Exemplo n.º 3
0
 public synchronized void unbindConnectionNode(OteServerJmsNodeProvider connectionNode) {
   connecitonNode.getConnectionNode().unsubscribe(BridgeMessages.BYTE_MESSAGE, this);
   this.connecitonNode = null;
 }