net-coroutines / org.apache.tuweni.net.coroutines / ScatteringCoroutineByteChannel

ScatteringCoroutineByteChannel

interface ScatteringCoroutineByteChannel : ReadableCoroutineByteChannel (source)

A channel that can read bytes into a sequence of buffers.

Functions

read

Reads a sequence of bytes from this channel into a subsequence of the given buffers.

abstract suspend fun read(dsts: Array<ByteBuffer>, offset: Int = 0, length: Int = dsts.size): Long

tryRead

Reads a sequence of bytes from this channel into a subsequence of the given buffers, if any are available.

abstract fun tryRead(dsts: Array<ByteBuffer>, offset: Int = 0, length: Int = dsts.size): Long

Inheritors

CoroutineDatagramChannel

A co-routine based datagram-oriented network channel.

class CoroutineDatagramChannel : CoroutineByteChannel, ScatteringCoroutineByteChannel, GatheringCoroutineByteChannel, CoroutineNetworkChannel

CoroutineSocketChannel

A co-routine based stream-oriented network channel.

class CoroutineSocketChannel : CoroutineByteChannel, ScatteringCoroutineByteChannel, GatheringCoroutineByteChannel, CoroutineNetworkChannel