/** How many recent samples each source keeps. */ export declare const SERVER_CLOCK_WINDOW = 9; /** Samples this close to the median agree with it. Wider than the `Date` header's 1 s resolution plus latency. */ export declare const SERVER_CLOCK_AGREEMENT_MS = 2000; export type ServerClockSource = 'room' | 'http'; export declare class ServerClock { private readonly deviceNow; private readonly windows; private readonly lastHeard; private heard; constructor(deviceNow?: () => number); /** A server timestamp (epoch ms) received at `receivedAt` (device epoch ms; default: now). Anything unusable is ignored. */ observe(serverMs: unknown, source: ServerClockSource, receivedAt?: number): void; /** * An HTTP `Date` header value (null when the browser did not expose it). The header is truncated to the * second, so the middle of that second is taken. */ observeHttpDate(header: string | null | undefined, receivedAt?: number): void; /** Server time minus device time, in ms, or null when no source is trusted yet. */ offsetMs(): number | null; /** The platform's time now (epoch ms): the device clock corrected by the trusted offset, or the device clock alone. */ now(): number; /** Whether `expiresAt` (epoch ms) has passed by the platform's clock. An unreadable expiry (NaN) never has. */ hasPassed(expiresAt: number): boolean; }