runCatchingSafely

inline suspend fun <T> runCatchingSafely(onException: ExceptionHandler<T>, block: suspend () -> T): Result<T>(source)

Launching block in runCatching. In case of failure, it will:

Return

Result with result of block if no exceptions or Result from onException execution


inline suspend fun <T, R> R.runCatchingSafely(onException: ExceptionHandler<T>, block: suspend R.() -> T): Result<T>(source)
inline suspend fun <T, R> R.runCatchingSafely(block: suspend R.() -> T): Result<T>(source)


inline suspend fun <T> runCatchingSafely(block: suspend () -> T): Result<T>(source)

Launching runCatchingSafely with defaultSafelyExceptionHandler as onException parameter