toList

suspend fun <E> ReceiveChannel<E>.toList(): List<E>

Returns a List containing all elements.

The operation is terminal. This function consumes all elements of the original ReceiveChannel.

Sources

common source
Link copied to clipboard