Transition

open class Transition<ID, V : Value<ID, V, S>, S : State<ID, V, S>>(val from: States<ID, V, S>, val to: S)

Constructors

Link copied to clipboard
constructor(from: S, to: S)
constructor(from: States<ID, V, S>, to: S)

Properties

Link copied to clipboard
val from: States<ID, V, S>
Link copied to clipboard
val to: S

Functions

Link copied to clipboard
open fun effect(value: V): Result<V>

The effect executed when transitioning from from to to.

Link copied to clipboard
open suspend fun effectAsync(value: V): Result<V>

The effect executed when transitioning from from to to, but only when using TransitionerAsync