export interface RetryOptions {
    args?: unknown[];
    backoffFactor?: number;
    baseDelayMs?: number;
    factor?: number;
    jitter?: boolean;
    maxDelayMs?: number;
    maxTimeout?: number;
    minTimeout?: number;
    onRetry?: (attempt: number, error: unknown, delay: number) => boolean | undefined;
    onRetryCancelOnFalse?: boolean;
    onRetryRethrow?: boolean;
    retries?: number;
    signal?: AbortSignal;
}
export interface IterationOptions {
    concurrency?: number;
    retries?: number | RetryOptions;
    signal?: AbortSignal;
}
/**
 * Normalize options for iteration functions.
 */
/*@__NO_SIDE_EFFECTS__*/
export declare function normalizeIterationOptions(options?: number | IterationOptions): {
    concurrency: number;
    retries: RetryOptions;
    signal: AbortSignal;
};
/**
 * Normalize options for retry functionality.
 */
/*@__NO_SIDE_EFFECTS__*/
export declare function normalizeRetryOptions(options?: number | RetryOptions): RetryOptions;
/**
 * Resolve retry options from various input formats.
 */
/*@__NO_SIDE_EFFECTS__*/
export declare function resolveRetryOptions(options?: number | RetryOptions): RetryOptions;
/**
 * Execute an async function for each array element with concurrency control.
 */
/*@__NO_SIDE_EFFECTS__*/
export declare function pEach<T>(array: T[], callbackFn: (item: T) => Promise<unknown>, options?: number | IterationOptions): Promise<void>;
/**
 * Filter an array asynchronously with concurrency control.
 */
/*@__NO_SIDE_EFFECTS__*/
export declare function pFilter<T>(array: T[], callbackFn: (item: T) => Promise<boolean>, options?: number | IterationOptions): Promise<T[]>;
/**
 * Process array in chunks with an async callback.
 */
/*@__NO_SIDE_EFFECTS__*/
export declare function pEachChunk<T>(array: T[], callbackFn: (chunk: T[]) => Promise<unknown>, options?: RetryOptions & {
    chunkSize?: number;
}): Promise<void>;
/**
 * Filter chunked arrays with an async predicate.
 */
/*@__NO_SIDE_EFFECTS__*/
export declare function pFilterChunk<T>(chunks: T[][], callbackFn: (value: T) => Promise<boolean>, options?: number | RetryOptions): Promise<T[][]>;
/**
 * Retry an async function with exponential backoff.
 * @throws {Error} The last error if all retries fail.
 */
/*@__NO_SIDE_EFFECTS__*/
export declare function pRetry<T>(callbackFn: (...args: unknown[]) => Promise<T>, options?: number | RetryOptions): Promise<T | undefined>;
