import { GetArgumentType } from './custom_type_guard.cjs';

declare function asyncAwaitMap<R, C = unknown>(_collections: C[] | number, doAsync: (iteration: C, index: number) => Promise<R>, concurrent?: number, options?: {
    doAfterEachBatch?: (batchResults: R[], batchIndex: number) => void | Promise<void>;
    breakCondition?: (accumulateResults: R[], iteration: number) => boolean | Promise<boolean>;
    mode?: `while` | `reduceLoop`;
}): Promise<R[]>;
declare const parallelLimit: typeof asyncAwaitMap;
declare const parallelLimitChunk: <R, C = unknown>(_collections: number | C[], doAsync: (chunk: C[], indexChunk: number) => Promise<R[]>, chunkSize?: number, options?: GetArgumentType<typeof parallelLimit>[3]) => Promise<R[]>;
declare const parallelLimitBatch: <R, C = unknown>(_collections: number | C[], doAsync: (chunk: C[], indexChunk: number) => Promise<R[]>, chunkSize?: number, options?: GetArgumentType<typeof parallelLimit>[3]) => Promise<R[]>;

export { asyncAwaitMap, parallelLimit, parallelLimitBatch, parallelLimitChunk };
