/** * Content-Length framing helpers for JSON-RPC over named pipes / stdio. * * Wire format: * Content-Length: \r\n\r\n */ /** * Encode a UTF-8 string into a Content-Length frame. */ export declare function encodeFrame(body: string): Buffer; /** * Find the end of the Content-Length header (position of \r\n\r\n). * Returns -1 if not yet present. */ export declare function findHeaderEnd(buf: Buffer): number; /** * Extract the Content-Length value from a header block. * Returns -1 if not parseable. */ export declare function parseContentLength(headerBlock: Buffer): number; /** * Given a buffer that may contain a complete Content-Length frame, * extract the body string. Throws if the frame is incomplete or header * is missing. */ export declare function decodeFrame(buf: Buffer): string; //# sourceMappingURL=framing.d.ts.map