flatMap<B> method

  1. @override
IO<B> flatMap<B>(
  1. covariant IO<B> f(
    1. A a
    )
)
override

Used to chain multiple functions that return a IO.

Implementation

@override
IO<B> flatMap<B>(covariant IO<B> Function(A a) f) => IO(() => f(run()).run());