import { type JSONObject } from 'tiny-types';
import { Duration } from './Duration.js';
import { Timestamp } from './Timestamp.js';
/**
 * A [`Clock`](https://serenity-js.org/api/core/class/Clock/) tells the time. This abstraction allows Serenity/JS to have a single place
 * in the framework responsible for telling the time, and one that can be easily mocked for internal testing.
 *
 * ```ts
 * const now: Timestamp = new Clock().now()
 * ```
 *
 * ## Learn more
 * - [`Timestamp`](https://serenity-js.org/api/core/class/Timestamp/)
 * - [`Duration`](https://serenity-js.org/api/core/class/Duration/)
 *
 * @group Time
 */
export declare class Clock {
    private readonly checkTime;
    private static resolution;
    private timeAdjustment;
    constructor(checkTime?: () => Date);
    toJSON(): JSONObject;
    /**
     * Sets the clock ahead to force early resolution of promises
     * returned by [`Clock.waitFor`](https://serenity-js.org/api/core/class/Clock/#waitFor).
     *
     * Useful for test purposes to avoid unnecessary delays.
     *
     * @param duration
     */
    setAhead(duration: Duration): void;
    /**
     * Returns a Promise that resolves after one tick of the clock.
     *
     * Useful for test purposes to avoid unnecessary delays.
     */
    tick(): Promise<void>;
    /**
     * Returns current time
     */
    now(): Timestamp;
    /**
     * Returns a Promise that will be resolved after the given duration
     *
     * @param duration
     */
    waitFor(duration: Duration): Promise<void>;
}
//# sourceMappingURL=Clock.d.ts.map