code: private boolean internalRead(Buffer buffer)
      {
          try
          {
              return !(buffer.readFrom(transport) < 0);
          }
          catch (IOException e)
          {
              logger.warn("Got an IOException in internalRead!", e);
              return false;
          }
      }
docs: Perform a read into dataBuffer.
  
  @return true if the read succeeded, false if there was an error or the
  connection closed.