import { AdapterInfo, JSONAdapter, NativeBindings, ParseError, Replacer, Result, Reviver, StringifyError } from '../types.js'; /** * Sonic (Rust SIMD) JSON adapter implementation * * Uses sonic-rs for SIMD-accelerated parsing and serialization. * On supported platforms, this can be 2-3x faster than native JSON. */ export declare class SonicAdapter implements JSONAdapter { readonly name: "sonic"; readonly isNative = false; private native; constructor(native: NativeBindings); /** * Parse a JSON string using sonic-rs */ parse(text: string, reviver?: Reviver): T; /** * Stringify a value using sonic-rs */ stringify(value: unknown, replacer?: Replacer, space?: number | string): string; /** * Deep clone via sonic-rs round-trip */ clone(value: T): T; /** * Parse without throwing */ safeParse(text: string): Result; /** * Stringify without throwing */ safeStringify(value: unknown): Result; /** * Validate JSON string using sonic-rs */ isValid(text: string): boolean; /** * Get adapter information */ getInfo(): AdapterInfo; /** * Apply reviver function to parsed value * @internal */ private applyReviver; private walkReviver; /** * Apply replacer to value before stringifying * @internal */ private applyReplacer; private walkReplacer; } /** * Try to create a SonicAdapter instance * Returns null if native bindings are not available */ export declare function createSonicAdapter(): SonicAdapter | null; /** * Check if sonic (Rust) adapter is available on this platform */ export declare function isSonicAvailable(): boolean; //# sourceMappingURL=sonic.d.ts.map