Package 

Class FlowsKt

    • Method Summary

      Modifier and Type Method Description
      final static <T extends Any> Unit update(MutableStateFlow<T> $self, T state) Updates the value of the MutableStateFlow with the given state.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • update

         final static <T extends Any> Unit update(MutableStateFlow<T> $self, T state)

        Updates the value of the MutableStateFlow with the given state. Internally calls MutableStateFlow.update with a lambda that always returns the given state. More readable than stateFlow.update { state }.

        Parameters:
        state - The new value to set.