LifecycleStartStopEffectScope
Receiver scope for LifecycleStartEffect that offers the onStopOrDispose clause to couple the ON_START effect. This should be the last statement in any call to LifecycleStartEffect.
This scope is also a LifecycleOwner to allow access to the (lifecycle)LifecycleStartStopEffectScope.lifecycle within the onStopOrDispose clause.
Parameters
The lifecycle being observed by this receiver scope
Functions
Provide the onStopOrDisposeEffect to the LifecycleStartEffect to run when the observer receives an (ON_STOP)Lifecycle.Event.ON_STOP event or must undergo cleanup.
LifecycleOwner's extension function for Lifecycle.repeatOnLifecycle to allow an easier call to the API from LifecycleOwners such as Activities and Fragments.
Run block with this LifecycleOwner's Lifecycle in a Lifecycle.State of at least Lifecycle.State.CREATED and resume with the result. Throws the CancellationException if the lifecycle has reached Lifecycle.State.DESTROYED by the time of the call or before block is able to run.
Run block with this LifecycleOwner's Lifecycle in a Lifecycle.State of at least Lifecycle.State.RESUMED and resume with the result. Throws the CancellationException if the lifecycle has reached Lifecycle.State.DESTROYED by the time of the call or before block is able to run.
Run block with this LifecycleOwner's Lifecycle in a Lifecycle.State of at least Lifecycle.State.STARTED and resume with the result. Throws the CancellationException if the lifecycle has reached Lifecycle.State.DESTROYED by the time of the call or before block is able to run.
Run block with this LifecycleOwner's Lifecycle in a Lifecycle.State of at least state and resume with the result. Throws the CancellationException if the lifecycle has reached Lifecycle.State.DESTROYED by the time of the call or before block is able to run.