CompletingSharedFlowCache

A cache of flows which each follow the behaviour of shareInCompleting - i.e. they share a single upstream and pass completion and errors on to the downstream.

Types

Link copied to clipboard
object Companion

Functions

Link copied to clipboard
abstract operator fun get(key: K, supplier: (K) -> Flow<T>): CompletingSharedFlow<T>

If the requested key K is not found in the cache when the CompletingSharedFlow returned by get is subscribed to, then the supplier function will be invoked. Any errors throw in supplier are thrown as error events within the flow.