resolve
inline fun <E, A, B> resolve( f: () -> Either<E, A>, success: (A) -> Either<Throwable, B>, error: (E) -> Either<Throwable, B>, throwable: (throwable: Throwable) -> Either<Throwable, B>, unrecoverableState: (throwable: Throwable) -> Either<Throwable, Unit>): B
Content copied to clipboard
The resolve function can resolve any suspended function that yields an Either into one type of value.
Return
the result of applying the resolve function.
Parameters
f
the function that needs to be resolved.
unrecoverable State
the function to apply if resolve is in an unrecoverable state.