public class InputStreamAdaptersKt
| Modifier and Type | Method and Description |
|---|---|
static kotlinx.coroutines.io.ByteReadChannel |
toByteReadChannel(java.io.InputStream $receiver,
kotlinx.io.pool.ObjectPool<java.nio.ByteBuffer> pool,
NonExistentClass context,
kotlinx.coroutines.Job parent)
Open a channel and launch a coroutine to copy bytes from the input stream to the channel.
Please note that it may block your async code when started on Dispatchers.Unconfined
since InputStream is blocking on it's nature
|
public static kotlinx.coroutines.io.ByteReadChannel toByteReadChannel(java.io.InputStream $receiver,
kotlinx.io.pool.ObjectPool<java.nio.ByteBuffer> pool,
NonExistentClass context,
kotlinx.coroutines.Job parent)
Open a channel and launch a coroutine to copy bytes from the input stream to the channel. Please note that it may block your async code when started on Dispatchers.Unconfined since InputStream is blocking on it's nature