whenAsync<R> method

  1. @override
Future<R> whenAsync<R>({
  1. required Future<R> ok(
    1. T
    ),
  2. required Future<R> err(
    1. E
    ),
})
override

Asynchronously invokes either ok or err depending on the result.

Identical to match except that the arguments are named.

Implementation

@override
Future<R> whenAsync<R>({
  required Future<R> Function(T) ok,
  required Future<R> Function(E) err,
}) =>
    err(_err);