2020-11-28 22:22:24 +00:00
|
|
|
package com.vanced.manager.core.mvi
|
|
|
|
|
|
|
|
import kotlinx.coroutines.flow.MutableSharedFlow
|
|
|
|
|
|
|
|
typealias Handler<State, Action, Modification, SideEffect> =
|
|
|
|
suspend MutableSharedFlow<Modification>.(
|
|
|
|
state: State,
|
|
|
|
action: Action,
|
2020-11-29 11:16:35 +00:00
|
|
|
sideEffectsFlow: MutableSharedFlow<SideEffect>,
|
2020-11-28 22:22:24 +00:00
|
|
|
) -> Unit
|
|
|
|
|
|
|
|
typealias Reducer<State, Modification> =
|
2020-11-30 09:08:14 +00:00
|
|
|
suspend MutableSharedFlow<State>.(
|
2020-11-28 22:22:24 +00:00
|
|
|
state: State,
|
|
|
|
modification: Modification
|
2020-11-30 09:08:14 +00:00
|
|
|
) -> Unit
|