/** * Constructor for the <code>SocketFlusher</code> object. This is * used to flush buffers to the underlying socket asynchronously. * When finished flushing all of the buffered data this signals * any threads that are blocking waiting for the write to finish. * * @param reactor this is used to perform asynchronous writes * @param writer this is used to write the buffered packets */ public SocketFlusher(Socket socket, Reactor reactor, PacketWriter writer) throws IOException { this.signaller = new Signaller(writer); this.scheduler = new Scheduler(socket, reactor, signaller, this); this.trace = socket.getTrace(); this.writer = writer; }