requireNoNulls

fun <E : Any> ReceiveChannel<E?>.requireNoNulls(): ReceiveChannel<E> (source)

Platform and version requirements: JVM

Returns an original collection containing all the non-null elements, throwing an IllegalArgumentException if there are any null elements.

The operation is intermediate and stateless. This function consumes all elements of the original ReceiveChannel.