import { type Clock, type Time } from "./clock"; export interface Retry { retryUntil(fn: () => Promise, predicate: (result: T) => boolean | Promise, onTimeout: () => U, timeoutMs: number): Promise; } declare abstract class AbstractRetry implements Retry { protected readonly clock: Clock; protected constructor(clock?: Clock); abstract retryUntil(fn: () => Promise, predicate: (result: T) => boolean | Promise, onTimeout: () => U, timeoutMs: number): Promise; protected hasTimedOut(timeoutMs: number, startTime: Time): boolean; protected wait(duration: number): Promise; } export declare class IntervalRetry extends AbstractRetry { private readonly interval; constructor(interval: number); retryUntil(fn: (attempt: number) => Promise, predicate: (result: T) => boolean | Promise, onTimeout: () => U, timeoutMs: number): Promise; } export {};