import { Types } from 'ably';
import Space from './Space.js';
import EventEmitter, { type EventKey, type EventListener } from './utilities/EventEmitter.js';
import type { CursorsOptions, CursorUpdate } from './types.js';
type CursorsEventMap = {
    update: CursorUpdate;
};
export default class Cursors extends EventEmitter<CursorsEventMap> {
    private space;
    private readonly cursorBatching;
    private readonly cursorDispensing;
    private readonly cursorHistory;
    readonly options: CursorsOptions;
    readonly channelName: string;
    channel?: Types.RealtimeChannelPromise;
    constructor(space: Space);
    /**
     * Schedules a cursor update event to be sent that will cause the following events to fire
     *
     * @param {CursorUpdate} cursor
     * @return {void}
     */
    set(cursor: Pick<CursorUpdate, 'position' | 'data'>): Promise<void>;
    private getChannel;
    private initializeCursorsChannel;
    private onPresenceUpdate;
    private isUnsubscribed;
    private emitterHasListeners;
    subscribe<K extends EventKey<CursorsEventMap>>(listenerOrEvents?: K | K[] | EventListener<CursorsEventMap[K]>, listener?: EventListener<CursorsEventMap[K]>): void;
    unsubscribe<K extends EventKey<CursorsEventMap>>(listenerOrEvents?: K | K[] | EventListener<CursorsEventMap[K]>, listener?: EventListener<CursorsEventMap[K]>): void;
    getSelf(): Promise<CursorUpdate | null>;
    getOthers(): Promise<Record<string, null | CursorUpdate>>;
    getAll(): Promise<Record<string, null | CursorUpdate>>;
}
export {};
