int checkReadArguments(byte[] dst, int offset, int length) {
    if (dst == null) throw new NullPointerException();
    if (offset < 0 || length < 0 || length > dst.length - offset) {
      throw new IndexOutOfBoundsException();
    }
    return Math.min(available(), length);
  }
@return the value read. Use {@link WriteBuffer#varintSizeInBytes(long)} to tell how many bytes.
@throws IllegalArgumentException if more than 64 bits were encoded
zipkin/src/main/java/zipkin2/internal/ReadBuffer.java