Decision

sealed interface Decision<in Input, out Output>(source)

Inheritors

Types

Link copied to clipboard
data class Continue<in Input, out Output>(val output: Output, val delay: Duration, val step: ScheduleStep<Input, Output>) : Schedule.Decision<Input, Output>
Link copied to clipboard
data class Done<out Output>(val output: Output) : Schedule.Decision<Any?, Output>

Properties

Link copied to clipboard
abstract val output: Output

Functions

Link copied to clipboard
open suspend fun <B, C> and(other: Schedule.Decision<@UnsafeVariance Input, B>, transform: suspend (output: Output, b: B) -> C, combineDuration: suspend (left: Duration, right: Duration) -> Duration): Schedule.Decision<Input, C>
Link copied to clipboard
open suspend fun <A, B> andThen(other: suspend (@UnsafeVariance Input) -> Schedule.Decision<@UnsafeVariance Input, A>, ifLeft: suspend (Output) -> B, ifRight: suspend (A) -> B): Schedule.Decision<Input, B>
Link copied to clipboard
open suspend fun <A> contramap(f: suspend (A) -> Input): Schedule.Decision<A, Output>
Link copied to clipboard
open suspend fun delayed(transform: suspend (Output, Duration) -> Duration): Schedule.Decision<Input, Output>
Link copied to clipboard
open suspend fun <A> map(f: suspend (output: Output) -> A): Schedule.Decision<Input, A>
Link copied to clipboard
open suspend fun <B, C> or(other: Schedule.Decision<@UnsafeVariance Input, B>, transform: suspend (output: Output?, b: B?) -> C, combineDuration: suspend (left: Duration?, right: Duration?) -> Duration): Schedule.Decision<Input, C>
Link copied to clipboard