Class ClientCnxnSocketNIO


  • public class ClientCnxnSocketNIO
    extends java.lang.Object
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected java.nio.ByteBuffer incomingBuffer
      After the length is read, a new incomingBuffer is allocated in readLength() to receive the full message.
      protected boolean initialized  
      protected long lastHeard  
      protected long lastSend  
      protected java.nio.ByteBuffer lenBuffer
      This buffer is only used to read the length of the incoming message.
      protected long now  
      protected long recvCount  
      protected org.apache.zookeeper.ClientCnxn.SendThread sendThread  
      protected long sentCount  
      protected long sessionId
      The sessionId is only available here for Log and Exception messages.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void disableWrite()  
      protected void readLength()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • initialized

        protected boolean initialized
      • lenBuffer

        protected final java.nio.ByteBuffer lenBuffer
        This buffer is only used to read the length of the incoming message.
      • incomingBuffer

        protected java.nio.ByteBuffer incomingBuffer
        After the length is read, a new incomingBuffer is allocated in readLength() to receive the full message.
      • sentCount

        protected long sentCount
      • recvCount

        protected long recvCount
      • lastHeard

        protected long lastHeard
      • lastSend

        protected long lastSend
      • now

        protected long now
      • sendThread

        protected org.apache.zookeeper.ClientCnxn.SendThread sendThread
      • sessionId

        protected long sessionId
        The sessionId is only available here for Log and Exception messages. Otherwise the socket doesn't need to know it.
    • Method Detail

      • disableWrite

        public void disableWrite()
      • readLength

        protected void readLength()
                           throws java.io.IOException
        Throws:
        java.io.IOException