Applies the onOk function to the value contained in Ok, otherwise it computes a default using onErr if it is an error.
onOk
Ok
onErr
Value folding function.
Error folding function.
Result to fold.
Output of either the onOk or onErr functions.
Applies the
onOkfunction to the value contained inOk, otherwise it computes a default usingonErrif it is an error.