https://kotlinlang.org logo
#coroutines
Title
# coroutines
r

rafal

07/27/2017, 12:02 PM
Copy code
channel.consumeEach {
   if(it.sth()){
     doSth()
  } else {
     // stop consuming - break out of consume
  }
}
e

elizarov

07/27/2017, 1:20 PM
@rafal Not yet, but it is planned to be supported in the near future, when support for inline suspend function is finished in Kotlin compiler
👍 1
5 Views