Code example for SelectionKey

Methods: attachinterestOps

0
    } 
  } 
 
  private void cleanUpAndFireCallback(SelectionKey key) {
    state = State.RESPONSE_READ;
    key.interestOps(0);
    // this ensures that the TAsyncMethod instance doesn't hang around 
    key.attach(null);
    client.onComplete();
    callback.onComplete((T)this);
  } 
 
  private void doReadingResponseSize() throws IOException { 
    if (transport.read(sizeBuffer) < 0) {
      throw new IOException("Read call frame size failed");
    } 
    if (sizeBuffer.remaining() == 0) {
      state = State.READING_RESPONSE_BODY;
      frameBuffer = ByteBuffer.allocate(TFramedTransport.decodeFrameSize(sizeBufferArray));
    } 
  }