import { Disposable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle"; import type { IChannel } from "@codingame/monaco-vscode-api/vscode/vs/base/parts/ipc/common/ipc"; import type { AhpServerNotification, JsonRpcResponse, ProtocolMessage } from "@codingame/monaco-vscode-api/vscode/vs/platform/agentHost/common/state/sessionProtocol"; import type { IClientTransport } from "../common/state/sessionTransport.js"; /** * Wraps an {@link IChannel} as an {@link IClientTransport} for the agent * host protocol. Frames are passed as JSON strings to avoid the IPC layer's * URI revival (URIs in AHP are string-typed on the wire). * * Wire shape: * - `listen('frame')` → emits each upstream JSON frame as a string. * - `listen('close')` → fires when the upstream connection closes. * - `call('connect')` → opens the upstream connection; resolves when ready. * - `call('send', frame)` → forwards a JSON frame upstream. */ export declare class AgentHostIpcChannelTransport extends Disposable implements IClientTransport { private readonly _channel; private readonly _onMessage; readonly onMessage: import("@codingame/monaco-vscode-api/vscode/vs/base/common/event").Event; private readonly _onClose; readonly onClose: import("@codingame/monaco-vscode-api/vscode/vs/base/common/event").Event; private _isOpen; private _closeFired; private _malformedFrames; constructor(_channel: IChannel); get isOpen(): boolean; connect(): Promise; send(message: ProtocolMessage | AhpServerNotification | JsonRpcResponse): void; dispose(): void; private _handleFrame; private _fireClose; }