consumeEachIndexed
inline suspend fun <E> ReceiveChannel<E>.consumeEachIndexed(
action: (IndexedValue<E>) -> Unit
): Unit
(source)Platform and version requirements: JVM
Performs the given action for each received element.
This function consumes all elements of the original ReceiveChannel.