import { QspErrorData, QspListItem, QspObjectItem } from '../contracts/common'; import { CharsPtr, ErrorPtr, Ptr, QspWasmModule, StringPtr, VariantPointer } from '../contracts/wasm-module'; import { QspTuple } from '../index-debug'; export declare const POINTER_SIZE = 4; export declare function allocStringPointer(module: QspWasmModule): Ptr; export declare function allocVariantPointer(module: QspWasmModule): VariantPointer; export declare function allocErrorInfoPointer(module: QspWasmModule): ErrorPtr; export declare function allocPointer(module: QspWasmModule): Ptr; export declare function derefPointer(module: QspWasmModule, ptr: Ptr): Ptr; export declare function movePointer(ptr: Ptr, times?: number): Ptr; export declare function freePointer(module: QspWasmModule, ptr: Ptr): void; export declare function readInt(module: QspWasmModule, ptr: Ptr): number; export declare function readString(module: QspWasmModule, ptr: StringPtr): string; export declare function writeString(module: QspWasmModule, value: string): CharsPtr; export declare function withStringRead(module: QspWasmModule, callback: (ptr: Ptr) => void): string; export declare function withStringWrite(module: QspWasmModule, value: string, callback: (ptr: Ptr) => void): void; export declare function withListRead(module: QspWasmModule, callback: (ptr: Ptr) => Ptr): QspListItem[]; export declare function withObjectRead(module: QspWasmModule, callback: (ptr: Ptr) => Ptr): QspObjectItem[]; export declare function withStringListRead(module: QspWasmModule, callback: (ptr: Ptr) => Ptr): string[]; export declare function withBufferWrite(module: QspWasmModule, data: ArrayBuffer, callback: (ptr: Ptr, size: number) => void): void; export declare function withBufferRead(module: QspWasmModule, callback: (ptr: Ptr) => Ptr): ArrayBuffer | null; export declare function readListItems(module: QspWasmModule, listPtr: Ptr, count: number): QspListItem[]; export declare function readObjectItems(module: QspWasmModule, listPtr: Ptr, count: number): QspObjectItem[]; export declare function readStringList(module: QspWasmModule, listPtr: Ptr, count: number): string[]; export declare function asAsync(module: QspWasmModule, callback: (done: (result?: number) => void) => void): void; export declare function writeUTF32String(module: QspWasmModule, str: string, outPtr: Ptr, maxBytesToWrite?: number): number; export declare function withVariantRead(module: QspWasmModule, name: string, callback: (ptr: VariantPointer) => void): string | number | QspTuple; export declare function readVariable(module: QspWasmModule, variant: VariantPointer, name?: string): string | number | QspTuple; export declare function readError(module: QspWasmModule, errorPtr: ErrorPtr): QspErrorData;