qisdk / com.aldebaran.qi.sdk.util / readAll

readAll

@JvmOverloads fun StreamableBuffer.readAll(chunkSize: Long = DEFAULT_CHUNK_SIZE): ByteBuffer

Read a StreamableBuffer entirely, chunk by chunk.

Parameters

chunkSize - the chunk size.

Receiver
the StreamableBuffer to be read.

Return
A ByteBuffer containing the entire StreamableBuffer data.

Since
7

@JvmOverloads fun Async.readAll(chunkSize: Long = DEFAULT_CHUNK_SIZE): Future<ByteBuffer>

Read a StreamableBuffer entirely, chunk by chunk, asynchronously.

Parameters

chunkSize - the chunk size.

Receiver
the StreamableBuffer.Async to be read.

Return
A Future that is completed when the StreamableBuffer is read entirely.

Since
7

@JvmOverloads fun StreamableBuffer.readAll(chunkSize: Long = DEFAULT_CHUNK_SIZE, onReadChunkFunction: (chunkBuffer: ByteBuffer) -> Unit): Unit

Read a StreamableBuffer entirely, chunk by chunk.

Parameters

chunkSize - the chunk size.

onReadChunkFunction - the function called for each chunk read, providing the chunk data.

Receiver
the StreamableBuffer to be read.

Since
7

@JvmOverloads fun StreamableBuffer.readAll(chunkSize: Long = DEFAULT_CHUNK_SIZE, onReadChunkConsumer: Consumer<ByteBuffer>): Unit

Read a StreamableBuffer entirely, chunk by chunk.

Parameters

chunkSize - the chunk size.

onReadChunkConsumer - the Consumer called for each chunk read, providing the chunk data.

Receiver
the StreamableBuffer to be read.

Since
7

@JvmOverloads fun Async.readAll(chunkSize: Long = DEFAULT_CHUNK_SIZE, onReadChunkFunction: (chunkBuffer: ByteBuffer) -> Unit): Future<Void>

Read a StreamableBuffer entirely, chunk by chunk, asynchronously.

Parameters

chunkSize - the chunk size.

onReadChunkFunction - the function called for each chunk read, providing the chunk data.

Receiver
the StreamableBuffer.Async to be read.

Return
A Future that is completed when the StreamableBuffer is read entirely.

Since
7

@JvmOverloads fun Async.readAll(chunkSize: Long = DEFAULT_CHUNK_SIZE, onReadChunkConsumer: Consumer<ByteBuffer>): Future<Void>

Read a StreamableBuffer entirely, chunk by chunk, asynchronously.

Parameters

chunkSize - the chunk size.

onReadChunkConsumer - the Consumer called for each chunk read, providing the chunk data.

Receiver
the StreamableBuffer.Async to be read.

Return
A Future that is completed when the StreamableBuffer is read entirely.

Since
7