data class Success<out T> : WebcomResult<T>
Represents a successful computation with a result of type T.
val failureError: WebcomError?
Gets the error of computation when failed, or |
|
val result: T
Result of the computation. |
fun get(): T
Gets the result of computation when successful, throws otherwise. |
|
fun getOrElse(default: T): T
Gets the result of the computation when successful, or a given default value otherwise. |
|
fun getOrNull(): T?
Gets the result of the computation when successful, or |
|
fun isSuccess(): Boolean
Indicates whether the computation was successful. |
|
fun <U> map(f: (T) -> U): WebcomResult<U>
Maps the result of this computation using the given f function. |