Companion

Functions

Link copied to clipboard
@JvmName(name = "tryCatch")
inline fun <R> catch(f: () -> R): Either<Throwable, R>
Link copied to clipboard
inline fun <E, A, B> resolve(f: () -> Either<E, A>, success: (a: A) -> Either<Throwable, B>, error: (e: E) -> Either<Throwable, B>, throwable: (throwable: Throwable) -> Either<Throwable, B>, unrecoverableState: (throwable: Throwable) -> Either<Throwable, Unit>): B

The resolve function can resolve any function that yields an Either into one type of value.