# Success

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

Successful result with value value.

#### Parameters

V

Type of the value.

## Constructors

Success
Link copied to clipboard
constructor(value: V)

## Properties

value
Link copied to clipboard
val value: V

## Functions

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

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

failure
Link copied to clipboard
fun SippoService<*>.failure(f: (Exception) -> Unit)

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

success
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.

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

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