-
public final class ContainerHostExtensionsKt
-
-
Method Summary
Modifier and Type Method Description final static <STATE extends Any, SIDE_EFFECT extends Any> UnitcollectSideEffect(ContainerHost<STATE, SIDE_EFFECT> $self, Lifecycle.State lifecycleState, SuspendFunction1<SIDE_EFFECT, Unit> sideEffect)Observe Container.sideEffectFlow in a Compose LaunchedEffect. final static <STATE extends Any, SIDE_EFFECT extends Any> UnitcollectState(ContainerHost<STATE, SIDE_EFFECT> $self, Lifecycle.State lifecycleState, SuspendFunction1<STATE, Unit> state)Observe Container.stateFlow in a Compose LaunchedEffect. final static <STATE extends Any, SIDE_EFFECT extends Any> State<STATE>collectAsState(ContainerHost<STATE, SIDE_EFFECT> $self, Lifecycle.State lifecycleState)Observe Container.stateFlow as State. -
-
Method Detail
-
collectSideEffect
@Composable() final static <STATE extends Any, SIDE_EFFECT extends Any> Unit collectSideEffect(ContainerHost<STATE, SIDE_EFFECT> $self, Lifecycle.State lifecycleState, SuspendFunction1<SIDE_EFFECT, Unit> sideEffect)
Observe Container.sideEffectFlow in a Compose LaunchedEffect.
Active subscriptions from this operator count towards repeatOnSubscription subscribers.
- Parameters:
lifecycleState- Lifecycle.State in which state block runs.
-
collectState
@Composable()@Deprecated(message = This API will no longer be supported for Compose. Use collectAsState or container.refCountStateFlow instead) final static <STATE extends Any, SIDE_EFFECT extends Any> Unit collectState(ContainerHost<STATE, SIDE_EFFECT> $self, Lifecycle.State lifecycleState, SuspendFunction1<STATE, Unit> state)
Observe Container.stateFlow in a Compose LaunchedEffect.
- Parameters:
lifecycleState- Lifecycle.State in which state block runs.
-
collectAsState
@Composable() final static <STATE extends Any, SIDE_EFFECT extends Any> State<STATE> collectAsState(ContainerHost<STATE, SIDE_EFFECT> $self, Lifecycle.State lifecycleState)
Observe Container.stateFlow as State.
- Parameters:
lifecycleState- The minimum lifecycle state at which the state is observed.
-
-
-
-