Reads size bytes from the native memory block and returns a ByteArray holding them.
The read starts at offset in the native memory region and writes into the returned ByteArray.
if the requested range is out of bounds in either the native memory block or the returned ByteArray.