unicorn-coroutines
/
ru.dimsuz.unicorn.coroutines
/
Machine
Machine
interface
Machine
<
S
:
Any
,
E
:
Any
>
Content copied to clipboard
Functions
Properties
Functions
send
Link copied to clipboard
abstract suspend fun
send
(e:
E
)
Content copied to clipboard
Sends event
e
to the machine, suspending in case event buffer is overflown.
trySend
Link copied to clipboard
abstract fun
trySend
(e:
E
):
Boolean
Content copied to clipboard
Tries to send an event
e
to the machine and returns
false
if calling
send
instead of
trySend
would suspend
Properties
states
Link copied to clipboard
abstract val
states
:
Flow
<
S
>
Content copied to clipboard