public void closeConnection() { readerAndWriter.close(); }
/** * Sends the reply to client held by this proxy. This method has to be called after client is * initialized. * * @param clientReply - reply send to underlying client * @throws IllegalStateException if called before client is initialized */ public void send(ClientReply clientReply) throws IOException { if (!initialized) { throw new IllegalStateException("Connection not initialized yet"); } readerAndWriter.send(clientReply.toByteArray()); }
public SelectorThread getSelectorThread() { return readerAndWriter.getSelectorThread(); }