flatMap<B> method

FutureOr<B> flatMap<B>(
  1. FutureOr<B> f(
    1. A a
    )
)

Implementation

FutureOr<B> flatMap<B>(FutureOr<B> Function(A a) f) {
  if (this is Future) {
    return (this as Future<A>).then(f);
  }

  return f(this as A);
}