AsyncWriteStream

A stream to write to. On Jvm & Native, blocking APIs are available via BufferedWriteStream.

On Jvm & Native, all Async functions utilize Dispatchers.IO under the hood when calling BufferedWriteStream functions.

NOTE: For Jvm & Android the kotlinx.coroutines.core dependency is needed when using Async functions.

expect class AsyncWriteStream(source)

A stream to write to. On Jvm & Native, blocking APIs are available via io.matthewnelson.kmp.process.BufferedWriteStream.

On Jvm & Native, all Async functions utilize Dispatchers.IO under the hood when calling BufferedWriteStream functions.

NOTE: For Jvm & Android the kotlinx.coroutines.core dependency is needed when using Async functions.

actual class AsyncWriteStream(source)

A stream to write to.

Functions

Link copied to clipboard
expect fun close()
actual fun close()
Link copied to clipboard
actual suspend fun closeAsync()
expect suspend fun closeAsync()
actual suspend fun closeAsync()
Link copied to clipboard
expect fun flush()
actual fun flush()
Link copied to clipboard
actual suspend fun flushAsync()
expect suspend fun flushAsync()
actual suspend fun flushAsync()
Link copied to clipboard
actual suspend fun writeAsync(buf: ByteArray)
actual suspend fun writeAsync(buf: ByteArray, offset: Int, len: Int)
expect suspend fun writeAsync(buf: ByteArray)
expect suspend fun writeAsync(buf: ByteArray, offset: Int, len: Int)
actual suspend fun writeAsync(buf: ByteArray)
actual suspend fun writeAsync(buf: ByteArray, offset: Int, len: Int)