asMemory

fun ByteBuffer.asMemory(startOffset: Int = 0, size: Int = limit()): Memory(source)

Wraps this ByteBuffer to Memory object.

Receiver

the byte buffer.

Return

the Memory object.

Parameters

startOffset

the start offset.

size

the size of memory to map.