Value

data class Value<out V>(val value: V) : Either<Nothing, V>

Constructors

Link copied to clipboard
constructor(value: V)

Properties

Link copied to clipboard
val value: V

Functions

Link copied to clipboard
inline fun <E, V> Either<E, V>.catchError(action: (E) -> Nothing): V
Link copied to clipboard
inline fun <V, E> Either<E, V>.doOnError(action: (E) -> Unit): Either<E, V>
Link copied to clipboard
inline fun <V, E> Either<E, V>.doOnValue(action: (V) -> Unit): Either<E, V>
Link copied to clipboard
infix inline fun <V, V2, E> Either<E, V>.flatMap(func: (V) -> Either<E, V2>): Either<E, V2>
Link copied to clipboard
infix inline fun <V, E, E2> Either<E, V>.flatMapError(func: (E) -> Either<E2, V>): Either<E2, V>
Link copied to clipboard
inline fun <E, V, A> Either<E, V>.fold(error: (E) -> A, value: (V) -> A): A
Link copied to clipboard
inline fun <E> Either<E, Unit>.foldUnit(error: (E) -> Unit)
Link copied to clipboard
fun <E, V> Either<E, V>.getError(): E?
Link copied to clipboard
fun <E, V> Either<E, V>.getValue(): V?
Link copied to clipboard
infix inline fun <V, V2, E> Either<E, V>.map(func: (V) -> V2): Either<E, V2>
Link copied to clipboard
infix inline fun <V, E, E2> Either<E, V>.mapError(func: (E) -> E2): Either<E2, V>
Link copied to clipboard
infix inline fun <V, V2, E> Either<E, List<V>>.mapIterable(func: (V) -> V2): Either<E, List<V2>>