import * as ws from 'ws';
import { ServerOptions, WebSocket } from 'ws';
import * as http from 'http';

interface ScreenReceiverSignalingHubOptions {
    logger?: (message: string) => void;
    createPeerId?: () => string;
}
interface CreateScreenReceiverWebSocketServerOptions {
    serverOptions: ServerOptions;
    hubOptions?: ScreenReceiverSignalingHubOptions;
}
declare class ScreenReceiverSignalingHub {
    private readonly rooms;
    private readonly clients;
    private readonly logger?;
    private readonly createPeerId;
    constructor(options?: ScreenReceiverSignalingHubOptions);
    attachClient(socket: WebSocket): void;
    close(): void;
    private parseMessage;
    private handleMessage;
    private joinRoom;
    private forwardSignal;
    private broadcast;
    private removeClient;
    private send;
    private log;
}
declare function createScreenReceiverWebSocketServer(options: CreateScreenReceiverWebSocketServerOptions): {
    wss: ws.Server<typeof WebSocket, typeof http.IncomingMessage>;
    hub: ScreenReceiverSignalingHub;
    close(): void;
};

export { type CreateScreenReceiverWebSocketServerOptions, ScreenReceiverSignalingHub, type ScreenReceiverSignalingHubOptions, createScreenReceiverWebSocketServer };
