These are chat archives for ReactiveX/RxJava

Mar 2018
Prashant Singhal
Mar 24 2018 09:59

In this file SampleMVI_ViewModel , I'm trying to decode this piece of code...

    private val intentFilter: ObservableTransformer<BrowseIntent, BrowseIntent> =
            ObservableTransformer<BrowseIntent, BrowseIntent> {
                it.publish {
                            it.filter({ intent -> intent !is BrowseIntent.InitialIntent }))

Is my understanding correct that this transformer is basically trying to ensure that the InitialIntent is published only once (whenever it occurs). Post that, it will never be published ever again?

David Karnok
Mar 24 2018 11:06
@PrashantSinghal Looks like so; it will make sure at most one InitialIntent value is passed along.
Prashant Singhal
Mar 24 2018 11:16
Thanks @akarnokd .