import { alamos } from '@synnaxlabs/alamos';
import { channel, framer } from '@synnaxlabs/client';
import { CrudeTimeSpan, Destructor, MultiSeries } from '@synnaxlabs/x';
import { Cache } from './cache/cache';
export type StreamHandler = (data: Map<channel.Key, MultiSeries>) => void;
interface StreamerProps {
    cache: Cache;
    openStreamer: framer.StreamOpener;
    instrumentation?: alamos.Instrumentation;
    streamUpdateDelay?: CrudeTimeSpan;
}
export declare class Streamer {
    private readonly props;
    private readonly mu;
    private readonly listeners;
    private streamerRunLoop;
    private streamer;
    private closed;
    constructor(props: StreamerProps);
    /** Implements StreamClient. */
    stream(handler: StreamHandler, keys: channel.Keys): Promise<Destructor>;
    private removeStreamHandler;
    private updateStreamer;
    private runStreamer;
    close(): Promise<void>;
}
export {};
//# sourceMappingURL=streamer.d.ts.map