unwrapOrElse abstract method
S
unwrapOrElse(
- S onError(
- F error
Returns the encapsulated value if this instance represents Ok
or the result of onError
function for
the encapsulated a Err value.
Note: This should not be used to determine is Ok or is Err, since when the success type is nullable,
the value returned can be null, which is ambiguous in meaning.
Implementation
S unwrapOrElse(S Function(F error) onError);