docs: public static final byte[] read(ReadableByteChannel ch, int length) throws IOException
      {
          ByteBuffer bb = ByteBuffer.allocate(length);
          readAll(ch, bb);
          if (bb.hasRemaining())
          {
              throw new EOFException("couldn't read "+length+" bytes");
          }
          return bb.array();
      }