コード例 #1
0
  protected UMOMessage doSend(UMOEvent event) throws Exception {
    sendMessage(event);

    if (useRemoteSync(event)) {
      Message response;

      if (groupChat != null) {
        response = groupChat.nextMessage(event.getTimeout());
      } else {
        response = chat.nextMessage(event.getTimeout());
      }

      if (response != null) {
        if (logger.isDebugEnabled()) {
          logger.debug("Got a response from chat: " + chat);
        }
        return new MuleMessage(connector.getMessageAdapter(response));
      }
    }
    return null;
  }
コード例 #2
0
 public UMOConnector getConnector() throws Exception {
   XmppConnector cnn = new XmppConnector();
   cnn.setName("xmppConnector");
   cnn.initialise();
   return cnn;
 }
コード例 #3
0
 protected void doConnect() throws Exception {
   if (xmppConnection == null) {
     UMOEndpointURI uri = endpoint.getEndpointURI();
     xmppConnection = connector.createXmppConnection(uri);
   }
 }