Success

class Success<out V : Any>(val value: V) : SippoService<V>

Successful result with value value.

Parameters

V

Type of the value.

Constructors

Link copied to clipboard
constructor(value: V)

Properties

Link copied to clipboard
val value: V

Functions

Link copied to clipboard
open override fun error(): Exception?

Returns the error associated. In case of Success, error will be null.

Link copied to clipboard

Calls the function f with a specific error when Either is failure.

Link copied to clipboard
fun <V : Any> SippoService<V>.success(f: (V) -> Unit)

Calls the function f with a specific value when SippoService is successful.

Link copied to clipboard
open override fun value(): V

Returns the value associated. In case of Failure, value will be null.