import { EventEmitter } from "node:events";
/**
 * LSPConnection - Handles JSON-RPC over stdio for a language server process.
 */
export declare class LSPConnection extends EventEmitter {
    private process;
    private idCounter;
    private pendingRequests;
    private buffer;
    constructor(command: string, args: string[]);
    sendRequest(method: string, params: any): Promise<any>;
    sendNotification(method: string, params: any): void;
    private writeMessage;
    private handleData;
    private handleMessage;
    terminate(): void;
}
