flatMap<B> method
Passes the success value of this ZIO to the given function, and replaces the result by executing the resulting ZIO.
Implementation
ZIO<R, E, B> flatMap<B>(
ZIO<R, E, B> Function(A _) f,
) =>
ZIO.from(
(ctx) => unsafeRun(ctx).then(
(ea) => ea.match(
(e) => Either.left(e),
(a) => f(a).unsafeRun(ctx),
),
),
);