Package-level declarations
Types
Link copied to clipboard
interface CancellableEffect
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Signals active state of a FlowEffect. Does not contain the actions emitted by the flow. The reducer controls what to do with the emitted actions and how to incorporate them in the State.
Link copied to clipboard
An EffectIdSource that generates monotonically increasing integers as ids, always incrementing by 1.
Link copied to clipboard
An EffectIdSource that iterates through a fixed list of configured EffectIds. Throws NoSuchElementException when the list has been exceeded.
Link copied to clipboard
class Store<S : State, A : Action>(reducer: Reducer<S, A>, initialState: S, coroutineDispatcher: CoroutineDispatcher = Dispatchers.Default, coroutineScopeName: String = DEFAULT_COROUTINE_SCOPE_NAME, effectIdSource: EffectIdSource = UUIDEffectIdSource(), logger: Logger = NoopLogger(), exceptionHandler: ExceptionHandler = ThrowingExceptionHandler, parentJob: Job? = null) : AutoCloseable
A construct for managing complex state safely in concurrent environments.
Link copied to clipboard
Link copied to clipboard
An EffectIdSource that generates random Uuids as EffectIds.
Functions
Link copied to clipboard
Link copied to clipboard
fun <A : Action> flowEffect(effectId: EffectId, triggerAction: A, ownerId: OwnerId? = null, block: suspend () -> Flow<A>): FlowEffect<A>
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun <A : Action, R, C : A> trackedEffect(effectId: EffectId, triggerAction: A, actionWrapper: (EffectState<R>) -> C, ownerId: OwnerId? = null, block: suspend () -> R): FlowEffect<A>
Link copied to clipboard
fun <A : Action, R, C : A> trackedFlowEffect(effectId: EffectId, triggerAction: A, actionWrapper: (FlowEffectEvent<R>) -> C, ownerId: OwnerId? = null, block: suspend () -> Flow<R>): FlowEffect<A>