fold<R> abstract method

R fold<R>(
  1. R onError(
    1. BaseError failure
    ),
  2. R onSuccess(
    1. T value
    )
)

Returns the result of applying one of the functions to this result.

Implementation

R fold<R>(
  R Function(BaseError failure) onError,
  R Function(T value) onSuccess,
);