code: public int drainTo(@NotNull byte[] array, int offset, int length) {
  		assert !isRecycled() : "Attempt to use recycled bytebuf";
  		assert length >= 0 && (offset + length) <= array.length;
  		assert head + length <= tail;
  		System.arraycopy(this.array, head, array, offset, length);
  		head += length;
  		return length;
  	}
docs: Drains bytes from this {@code ByteBuf} starting from current {@link #head}
  to a given byte array with specified offset and length.
  
  This {@code ByteBuf} must be not recycled.
  
  @param array array to which bytes will be drained to
  @param offset starting position in the destination data.
  The sum of the value and the {@code length} parameter
  must be smaller or equal to {@link #array} length
  @param length number of bytes to be drained to given array.
  Must be greater or equal to 0.
  The sum of the value and {@link #head}
  must be smaller or equal to {@link #tail}
  @return number of bytes that were drained.