Knio Context
data class KnioContext(val maxTaskBufferSize: Int = DEFAULT_TASK_BUFFER_SIZE, val maxStreamBufferSize: Int = DEFAULT_STREAM_BUFFER_SIZE, val byteBufferPool: ByteBufferPool = DEFAULT_BYTE_BUFFER_POOL, val channelFactory: ChannelFactory = DEFAULT_CHANNEL_FACTORY) : CoroutineContext.Element
The coroutine context element for the knio library.
Constructors
Link copied to clipboard
constructor(maxTaskBufferSize: Int = DEFAULT_TASK_BUFFER_SIZE, maxStreamBufferSize: Int = DEFAULT_STREAM_BUFFER_SIZE, byteBufferPool: ByteBufferPool = DEFAULT_BYTE_BUFFER_POOL, channelFactory: ChannelFactory = DEFAULT_CHANNEL_FACTORY)
Properties
Link copied to clipboard
The pool to use for acquiring ByteBuffer instances. This pool is used to create byte buffers, but other buffers types are also pulled from this pool and a view is created.
Link copied to clipboard
The factory to use for creating Channel instances.
Link copied to clipboard
Link copied to clipboard
The size of buffers used for streams. The memory used for these buffers depends on the data type. For example, a ByteBuffer is 1:1, but a CharBuffer is 2:1.
Link copied to clipboard
The size of buffers used for short-lived tasks. The memory used for these buffers depends on the data type. For example, a ByteBuffer is 1:1, but a CharBuffer is 2:1.