/** True if using native lz4-napi, false if using WASM */ export declare let usingNativeLz4: boolean; /** True if using native zstd-napi, false if using WASM */ export declare let usingNativeZstd: boolean; export declare function init(): Promise; export declare function concat(arrays: Uint8Array[]): Uint8Array; export declare function readUInt32LE(arr: Uint8Array, offset: number): number; export declare const Method: { readonly None: 2; readonly LZ4: 130; readonly ZSTD: 144; }; export type MethodCode = (typeof Method)[keyof typeof Method]; export type Compression = "lz4" | "zstd" | false; export declare function toMethodCode(compression: Compression): MethodCode; export declare function cityHash128LE(bytes: Uint8Array): Uint8Array; /** * Raw LZ4 block compression (no ClickHouse block wrapper, no frame headers). * Used internally for ClickHouse native block format. */ export declare function lz4CompressRaw(raw: Uint8Array): Uint8Array; /** * LZ4 frame compression for HTTP Content-Encoding. * Produces standard LZ4 frame format with magic number and checksums. * Only available with lz4-napi (Node.js), not in WASM builds. */ export declare function lz4CompressFrame(raw: Uint8Array): Uint8Array; /** * Raw ZSTD compression (no ClickHouse block wrapper). * Use for HTTP Content-Encoding compression. */ export declare function zstdCompressRaw(raw: Uint8Array, level?: number): Uint8Array; /** * Encode a block with ClickHouse native compression format. * @param raw - Uncompressed data * @param mode - Compression method * @returns Compressed block with checksum header */ export declare function encodeBlock(raw: Uint8Array, mode?: MethodCode): Uint8Array; /** Calculate required buffer size for encodeBlock output */ export declare function decodeBlock(block: Uint8Array): Uint8Array; export declare function decodeBlocks(data: Uint8Array): Uint8Array; //# sourceMappingURL=compression.d.ts.map