import * as Chunk from "../Collections/Immutable/Chunk/core.js"; import type { ExecutionStrategy } from "../Effect/ExecutionStrategy.js"; import type { Managed } from "./managed.js"; /** * Applies the function `f` to each element of the `Iterable` and * returns the results in a new `B[]`. * * For a parallel version of this method, see `forEachPar`. * If you do not need the results, see `forEachUnit` for a more efficient implementation. * * @ets_data_first forEach_ */ export declare function forEach(f: (a: A) => Managed, __trace?: string): (as: Iterable) => Managed>; /** * Applies the function `f` to each element of the `Iterable` and * returns the results in a new `B[]`. * * For a parallel version of this method, see `forEachPar_`. * If you do not need the results, see `forEachUnit_` for a more efficient implementation. */ export declare function forEach_(as: Iterable, f: (a: A) => Managed, __trace?: string): Managed>; /** * Applies the function `f` to each element of the `Iterable` in parallel, * and returns the results in a new `readonly B[]`. * * For a sequential version of this method, see `forEach`. */ export declare function forEachExec_(as: Iterable, es: ExecutionStrategy, f: (a: A) => Managed, __trace?: string): Managed>; /** * Applies the function `f` to each element of the `Iterable` in parallel, * and returns the results in a new `readonly B[]`. * * For a sequential version of this method, see `forEach`. * * @ets_data_first forEachExec_ */ export declare function forEachExec(es: ExecutionStrategy, f: (a: A) => Managed, __trace?: string): (as: Iterable) => Managed>; /** * Applies the function `f` to each element of the `Iterable[A]` and runs * produced effects sequentially. * * Equivalent to `forEach(as)(f).unit`, but without the cost of building * the list of results. */ export declare function forEachUnit_(as: Iterable, f: (a: A) => Managed, __trace?: string): Managed; /** * Applies the function `f` to each element of the `Iterable[A]` and runs * produced effects sequentially. * * Equivalent to `forEach(as)(f).unit`, but without the cost of building * the list of results. * * @ets_data_first forEachUnit_ */ export declare function forEachUnit(f: (a: A) => Managed, __trace?: string): (as: Iterable) => Managed; /** * Applies the function `f` to each element of the `Iterable` in parallel, * and returns the results in a new `B[]`. * * For a sequential version of this method, see `forEach`. * * @ets_data_first forEachPar_ */ export declare function forEachPar(f: (a: A) => Managed, __trace?: string): (as: Iterable) => Managed>; /** * Applies the function `f` to each element of the `Iterable` in parallel, * and returns the results in a new `B[]`. * * For a sequential version of this method, see `forEach_`. */ export declare function forEachPar_(as: Iterable, f: (a: A) => Managed, __trace?: string): Managed>; /** * Applies the function `f` to each element of the `Iterable` in parallel, * and returns the results in a new `B[]`. * * Unlike `forEachPar`, this method will use at most up to `n` fibers. * * @ets_data_first forEachParN_ */ export declare function forEachParN(n: number, f: (a: A) => Managed, __trace?: string): (as: Iterable) => Managed>; /** * Applies the function `f` to each element of the `Iterable` in parallel, * and returns the results in a new `B[]`. * * Unlike `forEachPar_`, this method will use at most up to `n` fibers. */ export declare function forEachParN_(as: Iterable, n: number, f: (a: A) => Managed, __trace?: string): Managed>; //# sourceMappingURL=forEach.d.ts.map