import * as A from "../../Collections/Immutable/Chunk"
import type * as Ex from "../../Exit"
import * as O from "../../Option"
import type * as Q from "../../Queue"
import * as T from "../_internal/effect"
import * as M from "../_internal/managed"
import type { Stream } from "./definitions"
/**
 * More powerful version of `broadcast`. Allows to provide a function that determines what
 * queues should receive which elements. The decide function will receive the indices of the queues
 * in the resulting list.
 */
export declare function distributedWith<O>(
  n: number,
  maximumLag: number,
  decide: (_: O) => T.UIO<(_: number) => boolean>
): <R, E>(
  self: Stream<R, E, O>
) => M.Managed<R, never, A.Chunk<Q.Dequeue<Ex.Exit<O.Option<E>, O>>>>
/**
 * More powerful version of `broadcast`. Allows to provide a function that determines what
 * queues should receive which elements. The decide function will receive the indices of the queues
 * in the resulting list.
 */
export declare function distributedWith_<R, E, O>(
  self: Stream<R, E, O>,
  n: number,
  maximumLag: number,
  decide: (_: O) => T.UIO<(_: number) => boolean>
): M.Managed<R, never, A.Chunk<Q.Dequeue<Ex.Exit<O.Option<E>, O>>>>
//# sourceMappingURL=distributedWith.d.ts.map
