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

Saiedmomen

08/15/2019, 5:57 PM
Also SAM conversion isn't working for FlowCollector interface for whatever reason
k

kingsley

08/15/2019, 6:21 PM
There is no SAM conversion though, as
FlowCollector
is a Kotlin interface. However, I believe what you’re looking for is the extension that takes
suspend (T) -> Unit
, but you’ll need to explicitly import
kotlinx.coroutines.flow.collect
👍 1
s

Saiedmomen

08/15/2019, 6:41 PM
yeah. that's awesome thank you
👍 1
e

elizarov

08/16/2019, 1:21 PM
import kotlinx.coroutines.flow.*
and be happy.
😀 2
😄 3
5 Views