getValueOrElse

open fun getValueOrElse(defaultFun: Expected.Transformer<E, V>): V

Retruns the value, if available, or produces a fallback with the provided function.

Return

or default value

Parameters

defaultFun

Function producing a default value based on an error.