Class DerivedStateFlow

  • All Implemented Interfaces:
    kotlinx.coroutines.flow.Flow , kotlinx.coroutines.flow.SharedFlow , kotlinx.coroutines.flow.StateFlow

    
    public final class DerivedStateFlow<T extends Object>
     implements StateFlow<T>
                        

    Does not produce the same value in a raw, so respect "distinct until changed emissions" https://github.com/Kotlin/kotlinx.coroutines/issues/2631#issuecomment-870565860

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private final List<T> replayCache
      private final T value
    • Constructor Summary

      Constructors 
      Constructor Description
      DerivedStateFlow(Function0<T> getValue, Flow<T> flow)
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      List<T> getReplayCache()
      T getValue()
      Void collect(FlowCollector<T> collector)
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait