Package org.eclipse.ecf.provider.filetransfer.events.socket

Examples of org.eclipse.ecf.provider.filetransfer.events.socket.SocketConnectedEvent


    }

    Socket toReturn;
    Socket wrapped = new CloseMonitoringSocket(sock, socketConnectListener, source);

    SocketConnectedEvent connectedEvent = new SocketConnectedEvent(source, sock, wrapped);
    fireEvent(socketConnectListener, connectedEvent);

    // Change the wrapped socket if one of the receivers of the SocketConnectedEvent changed it
    if (connectedEvent.getSocket() != wrapped) {
      toReturn = connectedEvent.getSocket();
      ((CloseMonitoringSocket) wrapped).setWrappedSocket(toReturn);
    } else {
      toReturn = wrapped;
    }
View Full Code Here


  }

  private Socket wrapSocket(Socket toWrap) {
    CloseMonitoringSocket wrappedSocket = new CloseMonitoringSocket(toWrap, socketConnectListener, source);

    SocketConnectedEvent connectedEvent = new SocketConnectedEvent(source, toWrap, wrappedSocket);
    fireEvent(socketConnectListener, connectedEvent);

    // Change the wrapped socket if one of the receivers of the SocketConnectedEvent changed it
    Socket connectedEventSocket = connectedEvent.getSocket();
    if (connectedEventSocket != wrappedSocket) {
      wrappedSocket.setWrappedSocket(connectedEventSocket);
      return connectedEventSocket;
    }
View Full Code Here

TOP

Related Classes of org.eclipse.ecf.provider.filetransfer.events.socket.SocketConnectedEvent

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.