public static @NotNull String toHexString(final @NotNull ByteBuffer buffer,
                                            final int pageSize) {
    final byte[] bytes = new byte[buffer.capacity()];
    final ByteBuffer slice = buffer.duplicate();
    slice.position(0)
      .limit(buffer.capacity());
    slice.get(bytes);
    return toHexString(bytes, pageSize);
  }
public static @NotNull String toHexString(final @NotNull ByteBuffer buffer,
                                            final int pageSize)