readBytes

abstract fun readBytes(b: ByteArray, offset: Int, len: Int)

Reads a specified number of bytes into an array at the specified offset.

Parameters

b

the array to read bytes into

offset

the offset in the array to start storing bytes

len

the number of bytes to read

See also


open fun readBytes(b: ByteArray, offset: Int, len: Int, useBuffer: Boolean)

Reads a specified number of bytes into an array at the specified offset with control over whether the read should be buffered (callers who have their own buffer should pass in "false" for useBuffer). Currently only BufferedIndexInput respects this parameter.

Parameters

b

the array to read bytes into

offset

the offset in the array to start storing bytes

len

the number of bytes to read

useBuffer

set to false if the caller will handle buffering.

See also