API reference › @evolu/sqlite-wasm › SqliteWasm
Defined in: packages/sqlite-wasm/src/Wasm.ts:200
A loaded SQLite wasm instance.
One instance serves every database of a worker. It cannot be disposed; it lives until the worker ends.
Properties
call
readonly call: <T>(fn: () => T) => T;
Defined in: packages/sqlite-wasm/src/Wasm.ts:230
Calls a function that calls into wasm, and returns its result.
Anything the function throws breaks the instance, as the module documentation explains: it is rethrown, and this and every later call throw without calling the function. Databases call wasm through it, and so should code that calls the CApi functions directly.
exports
readonly exports: SqliteCExports;
Defined in: packages/sqlite-wasm/src/Wasm.ts:208
The C functions, and the build's shims of the variadic ones, as the wasm exports them.
Prefer the standalone functions of @evolu/sqlite-wasm/c-api, which read
these once per database.
functionTable
readonly functionTable: Table;
Defined in: packages/sqlite-wasm/src/Wasm.ts:211
The wasm function table, where C function pointers point.
getHeapDataView
readonly getHeapDataView: () => DataView<ArrayBuffer>;
Defined in: packages/sqlite-wasm/src/Wasm.ts:220
Returns a DataView of the whole heap, like SqliteWasm.getHeapU8.
getHeapU8
readonly getHeapU8: () => Uint8Array<ArrayBuffer>;
Defined in: packages/sqlite-wasm/src/Wasm.ts:217
Returns a view of the whole heap, created again when memory has grown since the previous call.
isBroken
readonly isBroken: () => boolean;
Defined in: packages/sqlite-wasm/src/Wasm.ts:236
Whether an error escaped SqliteWasm.call, so the instance refuses calls.