Package org.jivesoftware.smack

Examples of org.jivesoftware.smack.ConnectionListener


        byteStreamTransferManager = new Socks5TransferNegotiator(connection);
        inbandTransferManager = new IBBTransferNegotiator(connection);
    }

    private void configureConnection(final Connection connection) {
        connection.addConnectionListener(new ConnectionListener() {
            public void connectionClosed() {
                cleanup(connection);
            }

            public void connectionClosedOnError(Exception e) {
View Full Code Here


        byteStreamTransferManager = new Socks5TransferNegotiatorManager(connection);
        inbandTransferManager = new IBBTransferNegotiator(connection);
    }

    private void configureConnection(final XMPPConnection connection) {
        connection.addConnectionListener(new ConnectionListener() {
            public void connectionClosed() {
                cleanup(connection);
            }

            public void connectionClosedOnError(Exception e) {
View Full Code Here

            }
        };

        // Create a thread that will listen for any connection closed event
        connListener = new ConnectionListener() {
            public void connectionClosed() {
                SwingUtilities.invokeLater(new Runnable() {
                    public void run() {
                        statusField.setValue("Closed");
                        EnhancedDebuggerWindow.connectionClosed(EnhancedDebugger.this);
View Full Code Here

                            packet.toXML());
                }
            }
        };

        connListener = new ConnectionListener() {
            public void connectionClosed() {
                System.out.println(
                        dateFormatter.format(new Date()) + " Connection closed (" +
                        connection.hashCode() +
                        ")");
View Full Code Here

            }
        };

        // Create a thread that will listen for any connection closed event
        connListener = new ConnectionListener() {
            public void connectionClosed() {
                SwingUtilities.invokeLater(new Runnable() {
                    public void run() {
                        statusField.setValue("Closed");
                        EnhancedDebuggerWindow.connectionClosed(EnhancedDebugger.this);
View Full Code Here

        byteStreamTransferManager = new Socks5TransferNegotiator(connection);
        inbandTransferManager = new IBBTransferNegotiator(connection);
    }

    private void configureConnection(final XMPPConnection connection) {
        connection.addConnectionListener(new ConnectionListener() {
            public void connectionClosed() {
                cleanup(connection);
            }

            public void connectionClosedOnError(Exception e) {
View Full Code Here

                            packet.toXML());
                }
            }
        };

        connListener = new ConnectionListener() {
            public void connectionClosed() {
                System.out.println(
                        dateFormatter.format(new Date()) + " Connection closed (" +
                        connection.hashCode() +
                        ")");
View Full Code Here

 
  @Override
  public void addConnectionListener(final IMConnectionListener listener) {
    lock();
    try {
      ConnectionListener l = new AbstractConnectionListener() {
        @Override
        public void connectionClosedOnError(Exception e) {
          listener.connectionBroken(e);
        }
      };
View Full Code Here

  @Override
  public void removeConnectionListener(IMConnectionListener listener) {
    lock();
    try {
      ConnectionListener l = this.listeners.remove(listener);
      if (l != null) {
        this.connection.removeConnectionListener(l);
      } else {
        LOGGER.warning("Connection listener " + listener + " not found.");
      }
View Full Code Here

                    LOGGER.finest("RCV PKT: " + packet.toXML());
                }
            }
        };

        this.connListener = new ConnectionListener() {
            public void connected(XMPPConnection connection) {
              if (LOGGER.isLoggable(MIN_LOG_LEVEL)) {
                    LOGGER.fine("Connection " + connection + " established");
                }
            }
View Full Code Here

TOP

Related Classes of org.jivesoftware.smack.ConnectionListener

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.