Package com.sun.sgs.impl.client.comm

Examples of com.sun.sgs.impl.client.comm.ClientConnection


            int port = msg.getInt();
            logger.log(Level.FINER, "Login redirect: {0}:{1}", host, port);

            // Disconnect our current connection, and connect to the
            // new host and port
            ClientConnection oldConnection = clientConnection;
            synchronized (SimpleClient.this) {
                clientConnection = null;
                connectionStateChanging = true;
            }
            try {
                oldConnection.disconnect();
            } catch (IOException e) {
                // ignore
                if (logger.isLoggable(Level.FINE)) {
                    logger.logThrow(Level.FINE, e,
                                    "Disconnecting after login redirect " +
View Full Code Here


     *
     * @param buf the data to send
     * @throws IOException if an IO problem occurs
     */
    private void sendRaw(ByteBuffer buf) throws IOException {
  ClientConnection conn = clientConnection;
  if (conn != null) {
      conn.sendMessage(buf);
  } else {
      throw new IOException("client disconnected or reconnecting");
  }
    }
View Full Code Here

    /**
     * Disconnects the underlying client connection.
     */
    private void disconnectClientConnection() throws IOException {
  ClientConnection conn = clientConnection;
  if (conn != null) {
      conn.disconnect();
  }
    }
View Full Code Here

      String host, int port, ClientConnectionListener listener)
      throws IOException
  {
            // Disconnect our current connection, and connect to the
            // new host and port
            ClientConnection oldConnection = clientConnection;
            synchronized (SimpleClient.this) {
                clientConnection = null;
                connectionStateChanging = true;
            }
            try {
                oldConnection.disconnect();
            } catch (IOException e) {
                // ignore
                if (logger.isLoggable(Level.FINE)) {
                    logger.logThrow(Level.FINE, e,
                                    "Disconnecting after login redirect " +
View Full Code Here

TOP

Related Classes of com.sun.sgs.impl.client.comm.ClientConnection

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.