@trust0/ridb-core 1.1.0 → 1.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/pkg/ridb_core.js CHANGED
@@ -20,6 +20,15 @@ function takeObject(idx) {
20
20
  return ret;
21
21
  }
22
22
 
23
+ function addHeapObject(obj) {
24
+ if (heap_next === heap.length) heap.push(heap.length + 1);
25
+ const idx = heap_next;
26
+ heap_next = heap[idx];
27
+
28
+ heap[idx] = obj;
29
+ return idx;
30
+ }
31
+
23
32
  const cachedTextDecoder = (typeof TextDecoder !== 'undefined' ? new TextDecoder('utf-8', { ignoreBOM: true, fatal: true }) : { decode: () => { throw Error('TextDecoder not available') } } );
24
33
 
25
34
  if (typeof TextDecoder !== 'undefined') { cachedTextDecoder.decode(); };
@@ -38,15 +47,6 @@ function getStringFromWasm0(ptr, len) {
38
47
  return cachedTextDecoder.decode(getUint8Memory0().subarray(ptr, ptr + len));
39
48
  }
40
49
 
41
- function addHeapObject(obj) {
42
- if (heap_next === heap.length) heap.push(heap.length + 1);
43
- const idx = heap_next;
44
- heap_next = heap[idx];
45
-
46
- heap[idx] = obj;
47
- return idx;
48
- }
49
-
50
50
  let WASM_VECTOR_LEN = 0;
51
51
 
52
52
  const cachedTextEncoder = (typeof TextEncoder !== 'undefined' ? new TextEncoder('utf-8') : { encode: () => { throw Error('TextEncoder not available') } } );
@@ -205,23 +205,20 @@ const CLOSURE_DTORS = (typeof FinalizationRegistry === 'undefined')
205
205
  wasm.__wbindgen_export_2.get(state.dtor)(state.a, state.b)
206
206
  });
207
207
 
208
- function makeMutClosure(arg0, arg1, dtor, f) {
208
+ function makeClosure(arg0, arg1, dtor, f) {
209
209
  const state = { a: arg0, b: arg1, cnt: 1, dtor };
210
210
  const real = (...args) => {
211
211
  // First up with a closure we increment the internal reference
212
212
  // count. This ensures that the Rust closure environment won't
213
213
  // be deallocated while we're invoking it.
214
214
  state.cnt++;
215
- const a = state.a;
216
- state.a = 0;
217
215
  try {
218
- return f(a, state.b, ...args);
216
+ return f(state.a, state.b, ...args);
219
217
  } finally {
220
218
  if (--state.cnt === 0) {
221
- wasm.__wbindgen_export_2.get(state.dtor)(a, state.b);
219
+ wasm.__wbindgen_export_2.get(state.dtor)(state.a, state.b);
220
+ state.a = 0;
222
221
  CLOSURE_DTORS.unregister(state);
223
- } else {
224
- state.a = a;
225
222
  }
226
223
  }
227
224
  };
@@ -229,29 +226,39 @@ function makeMutClosure(arg0, arg1, dtor, f) {
229
226
  CLOSURE_DTORS.register(real, state, state);
230
227
  return real;
231
228
  }
232
- function __wbg_adapter_56(arg0, arg1, arg2) {
233
- wasm._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h4279c525cebb26f2(arg0, arg1, addHeapObject(arg2));
234
- }
235
-
236
- function __wbg_adapter_61(arg0, arg1, arg2) {
237
- const ret = wasm._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h8fc6c6f4e4fe440c(arg0, arg1, addHeapObject(arg2));
238
- return takeObject(ret);
229
+ function __wbg_adapter_56(arg0, arg1, arg2, arg3, arg4) {
230
+ try {
231
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
232
+ wasm._dyn_core__ops__function__Fn__A_B_C___Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__hb43f4ea73c3b7f8b(retptr, arg0, arg1, addHeapObject(arg2), addHeapObject(arg3), addHeapObject(arg4));
233
+ var r0 = getInt32Memory0()[retptr / 4 + 0];
234
+ var r1 = getInt32Memory0()[retptr / 4 + 1];
235
+ var r2 = getInt32Memory0()[retptr / 4 + 2];
236
+ if (r2) {
237
+ throw takeObject(r1);
238
+ }
239
+ return takeObject(r0);
240
+ } finally {
241
+ wasm.__wbindgen_add_to_stack_pointer(16);
242
+ }
239
243
  }
240
244
 
241
- function makeClosure(arg0, arg1, dtor, f) {
245
+ function makeMutClosure(arg0, arg1, dtor, f) {
242
246
  const state = { a: arg0, b: arg1, cnt: 1, dtor };
243
247
  const real = (...args) => {
244
248
  // First up with a closure we increment the internal reference
245
249
  // count. This ensures that the Rust closure environment won't
246
250
  // be deallocated while we're invoking it.
247
251
  state.cnt++;
252
+ const a = state.a;
253
+ state.a = 0;
248
254
  try {
249
- return f(state.a, state.b, ...args);
255
+ return f(a, state.b, ...args);
250
256
  } finally {
251
257
  if (--state.cnt === 0) {
252
- wasm.__wbindgen_export_2.get(state.dtor)(state.a, state.b);
253
- state.a = 0;
258
+ wasm.__wbindgen_export_2.get(state.dtor)(a, state.b);
254
259
  CLOSURE_DTORS.unregister(state);
260
+ } else {
261
+ state.a = a;
255
262
  }
256
263
  }
257
264
  };
@@ -259,32 +266,17 @@ function makeClosure(arg0, arg1, dtor, f) {
259
266
  CLOSURE_DTORS.register(real, state, state);
260
267
  return real;
261
268
  }
262
- function __wbg_adapter_64(arg0, arg1, arg2, arg3, arg4) {
263
- try {
264
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
265
- wasm._dyn_core__ops__function__Fn__A_B_C___Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h80335dc7fe1c3f7e(retptr, arg0, arg1, addHeapObject(arg2), addHeapObject(arg3), addHeapObject(arg4));
266
- var r0 = getInt32Memory0()[retptr / 4 + 0];
267
- var r1 = getInt32Memory0()[retptr / 4 + 1];
268
- var r2 = getInt32Memory0()[retptr / 4 + 2];
269
- if (r2) {
270
- throw takeObject(r1);
271
- }
272
- return takeObject(r0);
273
- } finally {
274
- wasm.__wbindgen_add_to_stack_pointer(16);
275
- }
269
+ function __wbg_adapter_59(arg0, arg1, arg2) {
270
+ wasm._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h57c5f273361b47b1(arg0, arg1, addHeapObject(arg2));
276
271
  }
277
272
 
278
- function __wbg_adapter_67(arg0, arg1, arg2) {
279
- wasm._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__ha1155a5e1cc6e1e8(arg0, arg1, addHeapObject(arg2));
273
+ function __wbg_adapter_64(arg0, arg1, arg2) {
274
+ const ret = wasm._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__hfb3063b9244661be(arg0, arg1, addHeapObject(arg2));
275
+ return takeObject(ret);
280
276
  }
281
277
 
282
- let stack_pointer = 128;
283
-
284
- function addBorrowedObject(obj) {
285
- if (stack_pointer == 1) throw new Error('out of js stack');
286
- heap[--stack_pointer] = obj;
287
- return stack_pointer;
278
+ function __wbg_adapter_67(arg0, arg1, arg2) {
279
+ wasm._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__hc0ac713d063ee923(arg0, arg1, addHeapObject(arg2));
288
280
  }
289
281
 
290
282
  function _assertClass(instance, klass) {
@@ -303,14 +295,23 @@ function getUint32Memory0() {
303
295
  return cachedUint32Memory0;
304
296
  }
305
297
 
306
- function passArrayJsValueToWasm0(array, malloc) {
307
- const ptr = malloc(array.length * 4, 4) >>> 0;
298
+ function getArrayJsValueFromWasm0(ptr, len) {
299
+ ptr = ptr >>> 0;
308
300
  const mem = getUint32Memory0();
309
- for (let i = 0; i < array.length; i++) {
310
- mem[ptr / 4 + i] = addHeapObject(array[i]);
301
+ const slice = mem.subarray(ptr / 4, ptr / 4 + len);
302
+ const result = [];
303
+ for (let i = 0; i < slice.length; i++) {
304
+ result.push(takeObject(slice[i]));
311
305
  }
312
- WASM_VECTOR_LEN = array.length;
313
- return ptr;
306
+ return result;
307
+ }
308
+
309
+ let stack_pointer = 128;
310
+
311
+ function addBorrowedObject(obj) {
312
+ if (stack_pointer == 1) throw new Error('out of js stack');
313
+ heap[--stack_pointer] = obj;
314
+ return stack_pointer;
314
315
  }
315
316
 
316
317
  function handleError(f, args) {
@@ -320,6 +321,16 @@ function handleError(f, args) {
320
321
  wasm.__wbindgen_exn_store(addHeapObject(e));
321
322
  }
322
323
  }
324
+
325
+ function passArrayJsValueToWasm0(array, malloc) {
326
+ const ptr = malloc(array.length * 4, 4) >>> 0;
327
+ const mem = getUint32Memory0();
328
+ for (let i = 0; i < array.length; i++) {
329
+ mem[ptr / 4 + i] = addHeapObject(array[i]);
330
+ }
331
+ WASM_VECTOR_LEN = array.length;
332
+ return ptr;
333
+ }
323
334
  /**
324
335
  */
325
336
  export function main_js() {
@@ -334,16 +345,6 @@ export function is_debug_mode() {
334
345
  return ret !== 0;
335
346
  }
336
347
 
337
- function getArrayJsValueFromWasm0(ptr, len) {
338
- ptr = ptr >>> 0;
339
- const mem = getUint32Memory0();
340
- const slice = mem.subarray(ptr / 4, ptr / 4 + len);
341
- const result = [];
342
- for (let i = 0; i < slice.length; i++) {
343
- result.push(takeObject(slice[i]));
344
- }
345
- return result;
346
- }
347
348
  /**
348
349
  * Handler for `console.log` invocations.
349
350
  *
@@ -409,16 +410,16 @@ export function __wbgtest_console_error(args) {
409
410
  }
410
411
  }
411
412
 
412
- function __wbg_adapter_253(arg0, arg1) {
413
- wasm.wasm_bindgen__convert__closures__invoke0_mut__h19fc1620bec787be(arg0, arg1);
413
+ function __wbg_adapter_265(arg0, arg1) {
414
+ wasm.wasm_bindgen__convert__closures__invoke0_mut__haf3b101083ea1baf(arg0, arg1);
414
415
  }
415
416
 
416
- function __wbg_adapter_296(arg0, arg1, arg2, arg3, arg4) {
417
- wasm.wasm_bindgen__convert__closures__invoke3_mut__h7b738c7e28e951e8(arg0, arg1, addHeapObject(arg2), arg3, addHeapObject(arg4));
417
+ function __wbg_adapter_308(arg0, arg1, arg2, arg3, arg4) {
418
+ wasm.wasm_bindgen__convert__closures__invoke3_mut__h2c719ebcebf5f8cb(arg0, arg1, addHeapObject(arg2), arg3, addHeapObject(arg4));
418
419
  }
419
420
 
420
- function __wbg_adapter_349(arg0, arg1, arg2, arg3) {
421
- wasm.wasm_bindgen__convert__closures__invoke2_mut__h3a3f5f08be32a04a(arg0, arg1, addHeapObject(arg2), addHeapObject(arg3));
421
+ function __wbg_adapter_361(arg0, arg1, arg2, arg3) {
422
+ wasm.wasm_bindgen__convert__closures__invoke2_mut__h1ff4641e5edbc834(arg0, arg1, addHeapObject(arg2), addHeapObject(arg3));
422
423
  }
423
424
 
424
425
  /**
@@ -573,6 +574,24 @@ export class BaseStorage {
573
574
  }
574
575
  }
575
576
  /**
577
+ * @returns {any}
578
+ */
579
+ addIndexSchemas() {
580
+ try {
581
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
582
+ wasm.basestorage_addIndexSchemas(retptr, this.__wbg_ptr);
583
+ var r0 = getInt32Memory0()[retptr / 4 + 0];
584
+ var r1 = getInt32Memory0()[retptr / 4 + 1];
585
+ var r2 = getInt32Memory0()[retptr / 4 + 2];
586
+ if (r2) {
587
+ throw takeObject(r1);
588
+ }
589
+ return takeObject(r0);
590
+ } finally {
591
+ wasm.__wbindgen_add_to_stack_pointer(16);
592
+ }
593
+ }
594
+ /**
576
595
  * @param {string} name
577
596
  * @returns {any}
578
597
  */
@@ -700,13 +719,13 @@ export class Collection {
700
719
  /**
701
720
  * Finds and returns all documents in the collection.
702
721
  *
703
- * This function is asynchronous and returns a `Schema` representing
722
+ * This function is asynchronous and returns a `JsValue` representing
704
723
  * the documents found in the collection.
705
- * @param {any} query
724
+ * @param {any} query_js
706
725
  * @returns {Promise<any>}
707
726
  */
708
- find(query) {
709
- const ret = wasm.collection_find(this.__wbg_ptr, addHeapObject(query));
727
+ find(query_js) {
728
+ const ret = wasm.collection_find(this.__wbg_ptr, addHeapObject(query_js));
710
729
  return takeObject(ret);
711
730
  }
712
731
  /**
@@ -714,11 +733,11 @@ export class Collection {
714
733
  *
715
734
  * This function is asynchronous and returns a `Schema` representing
716
735
  * the documents found in the collection.
717
- * @param {any} query
736
+ * @param {any} query_js
718
737
  * @returns {Promise<any>}
719
738
  */
720
- count(query) {
721
- const ret = wasm.collection_count(this.__wbg_ptr, addHeapObject(query));
739
+ count(query_js) {
740
+ const ret = wasm.collection_count(this.__wbg_ptr, addHeapObject(query_js));
722
741
  return takeObject(ret);
723
742
  }
724
743
  /**
@@ -812,12 +831,12 @@ export class CoreStorage {
812
831
  * @param {any} value
813
832
  * @returns {string}
814
833
  */
815
- getPrimaryKey(value) {
834
+ getPrimaryKeyTyped(value) {
816
835
  let deferred2_0;
817
836
  let deferred2_1;
818
837
  try {
819
838
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
820
- wasm.corestorage_getPrimaryKey(retptr, this.__wbg_ptr, addHeapObject(value));
839
+ wasm.corestorage_getPrimaryKeyTyped(retptr, this.__wbg_ptr, addHeapObject(value));
821
840
  var r0 = getInt32Memory0()[retptr / 4 + 0];
822
841
  var r1 = getInt32Memory0()[retptr / 4 + 1];
823
842
  var r2 = getInt32Memory0()[retptr / 4 + 2];
@@ -837,6 +856,31 @@ export class CoreStorage {
837
856
  }
838
857
  }
839
858
  /**
859
+ * @param {Schema} schema
860
+ * @param {Operation} op
861
+ * @returns {(string)[]}
862
+ */
863
+ getIndexes(schema, op) {
864
+ try {
865
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
866
+ _assertClass(schema, Schema);
867
+ _assertClass(op, Operation);
868
+ wasm.corestorage_getIndexes(retptr, this.__wbg_ptr, schema.__wbg_ptr, op.__wbg_ptr);
869
+ var r0 = getInt32Memory0()[retptr / 4 + 0];
870
+ var r1 = getInt32Memory0()[retptr / 4 + 1];
871
+ var r2 = getInt32Memory0()[retptr / 4 + 2];
872
+ var r3 = getInt32Memory0()[retptr / 4 + 3];
873
+ if (r3) {
874
+ throw takeObject(r2);
875
+ }
876
+ var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
877
+ wasm.__wbindgen_free(r0, r1 * 4, 4);
878
+ return v1;
879
+ } finally {
880
+ wasm.__wbindgen_add_to_stack_pointer(16);
881
+ }
882
+ }
883
+ /**
840
884
  * @param {any} document
841
885
  * @param {Query} query
842
886
  * @returns {boolean}
@@ -992,24 +1036,6 @@ export class InMemory {
992
1036
  return takeObject(ret);
993
1037
  }
994
1038
  /**
995
- * @returns {any}
996
- */
997
- get by_index() {
998
- try {
999
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
1000
- wasm.inmemory_by_index(retptr, this.__wbg_ptr);
1001
- var r0 = getInt32Memory0()[retptr / 4 + 0];
1002
- var r1 = getInt32Memory0()[retptr / 4 + 1];
1003
- var r2 = getInt32Memory0()[retptr / 4 + 2];
1004
- if (r2) {
1005
- throw takeObject(r1);
1006
- }
1007
- return takeObject(r0);
1008
- } finally {
1009
- wasm.__wbindgen_add_to_stack_pointer(16);
1010
- }
1011
- }
1012
- /**
1013
1039
  * @param {Operation} op
1014
1040
  * @returns {Promise<any>}
1015
1041
  */
@@ -1020,13 +1046,13 @@ export class InMemory {
1020
1046
  }
1021
1047
  /**
1022
1048
  * @param {string} collection_name
1023
- * @param {any} query
1049
+ * @param {any} query_js
1024
1050
  * @returns {Promise<any>}
1025
1051
  */
1026
- find(collection_name, query) {
1052
+ find(collection_name, query_js) {
1027
1053
  const ptr0 = passStringToWasm0(collection_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
1028
1054
  const len0 = WASM_VECTOR_LEN;
1029
- const ret = wasm.inmemory_find(this.__wbg_ptr, ptr0, len0, addHeapObject(query));
1055
+ const ret = wasm.inmemory_find(this.__wbg_ptr, ptr0, len0, addHeapObject(query_js));
1030
1056
  return takeObject(ret);
1031
1057
  }
1032
1058
  /**
@@ -1042,13 +1068,13 @@ export class InMemory {
1042
1068
  }
1043
1069
  /**
1044
1070
  * @param {string} collection_name
1045
- * @param {any} query
1071
+ * @param {any} query_js
1046
1072
  * @returns {Promise<any>}
1047
1073
  */
1048
- count(collection_name, query) {
1074
+ count(collection_name, query_js) {
1049
1075
  const ptr0 = passStringToWasm0(collection_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
1050
1076
  const len0 = WASM_VECTOR_LEN;
1051
- const ret = wasm.inmemory_count(this.__wbg_ptr, ptr0, len0, addHeapObject(query));
1077
+ const ret = wasm.inmemory_count(this.__wbg_ptr, ptr0, len0, addHeapObject(query_js));
1052
1078
  return takeObject(ret);
1053
1079
  }
1054
1080
  /**
@@ -1094,6 +1120,43 @@ export class IndexDB {
1094
1120
  wasm.__wbg_indexdb_free(ptr);
1095
1121
  }
1096
1122
  /**
1123
+ * @returns {(string)[]}
1124
+ */
1125
+ get_stores() {
1126
+ try {
1127
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
1128
+ wasm.indexdb_get_stores(retptr, this.__wbg_ptr);
1129
+ var r0 = getInt32Memory0()[retptr / 4 + 0];
1130
+ var r1 = getInt32Memory0()[retptr / 4 + 1];
1131
+ var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
1132
+ wasm.__wbindgen_free(r0, r1 * 4, 4);
1133
+ return v1;
1134
+ } finally {
1135
+ wasm.__wbindgen_add_to_stack_pointer(16);
1136
+ }
1137
+ }
1138
+ /**
1139
+ * @param {string} store_name
1140
+ * @returns {IDBObjectStore}
1141
+ */
1142
+ get_store(store_name) {
1143
+ try {
1144
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
1145
+ const ptr0 = passStringToWasm0(store_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
1146
+ const len0 = WASM_VECTOR_LEN;
1147
+ wasm.indexdb_get_store(retptr, this.__wbg_ptr, ptr0, len0);
1148
+ var r0 = getInt32Memory0()[retptr / 4 + 0];
1149
+ var r1 = getInt32Memory0()[retptr / 4 + 1];
1150
+ var r2 = getInt32Memory0()[retptr / 4 + 2];
1151
+ if (r2) {
1152
+ throw takeObject(r1);
1153
+ }
1154
+ return takeObject(r0);
1155
+ } finally {
1156
+ wasm.__wbindgen_add_to_stack_pointer(16);
1157
+ }
1158
+ }
1159
+ /**
1097
1160
  * @param {string} name
1098
1161
  * @param {object} schemas_js
1099
1162
  * @returns {Promise<IndexDB>}
@@ -1238,26 +1301,54 @@ export class Operation {
1238
1301
  return takeObject(ret);
1239
1302
  }
1240
1303
  /**
1241
- * Retrieves the indexes related to the operation.
1304
+ * Retrieves the primary key field of the current collection.
1242
1305
  *
1243
1306
  * # Returns
1244
1307
  *
1245
- * * `Result<JsValue, JsValue>` - A result containing the indexes as a `JsValue` or an error.
1308
+ * * `Option<String>` - The primary key field of the current collection.
1246
1309
  * @returns {any}
1247
1310
  */
1248
- get indexes() {
1311
+ get primaryKeyField() {
1312
+ const ret = wasm.operation_primaryKeyField(this.__wbg_ptr);
1313
+ return takeObject(ret);
1314
+ }
1315
+ /**
1316
+ * Retrieves the primary key value of the current data.
1317
+ *
1318
+ * # Returns
1319
+ *
1320
+ * * `Option<JsValue>` - The primary key value of the current data.
1321
+ * @returns {any}
1322
+ */
1323
+ get primaryKey() {
1324
+ const ret = wasm.operation_primaryKey(this.__wbg_ptr);
1325
+ return takeObject(ret);
1326
+ }
1327
+ /**
1328
+ * @returns {string}
1329
+ */
1330
+ get primaryKeyIndex() {
1331
+ let deferred2_0;
1332
+ let deferred2_1;
1249
1333
  try {
1250
1334
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
1251
- wasm.operation_indexes(retptr, this.__wbg_ptr);
1335
+ wasm.operation_primaryKeyIndex(retptr, this.__wbg_ptr);
1252
1336
  var r0 = getInt32Memory0()[retptr / 4 + 0];
1253
1337
  var r1 = getInt32Memory0()[retptr / 4 + 1];
1254
1338
  var r2 = getInt32Memory0()[retptr / 4 + 2];
1255
- if (r2) {
1256
- throw takeObject(r1);
1339
+ var r3 = getInt32Memory0()[retptr / 4 + 3];
1340
+ var ptr1 = r0;
1341
+ var len1 = r1;
1342
+ if (r3) {
1343
+ ptr1 = 0; len1 = 0;
1344
+ throw takeObject(r2);
1257
1345
  }
1258
- return takeObject(r0);
1346
+ deferred2_0 = ptr1;
1347
+ deferred2_1 = len1;
1348
+ return getStringFromWasm0(ptr1, len1);
1259
1349
  } finally {
1260
1350
  wasm.__wbindgen_add_to_stack_pointer(16);
1351
+ wasm.__wbindgen_free(deferred2_0, deferred2_1, 1);
1261
1352
  }
1262
1353
  }
1263
1354
  }
@@ -1515,6 +1606,29 @@ export class Query {
1515
1606
  }
1516
1607
  }
1517
1608
  /**
1609
+ * Returns the schema properties (fields) that are used in the query.
1610
+ * The query may contain operators like $and, $or, $gt, $lt, etc.
1611
+ * @returns {(string)[]}
1612
+ */
1613
+ get_properties() {
1614
+ try {
1615
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
1616
+ wasm.query_get_properties(retptr, this.__wbg_ptr);
1617
+ var r0 = getInt32Memory0()[retptr / 4 + 0];
1618
+ var r1 = getInt32Memory0()[retptr / 4 + 1];
1619
+ var r2 = getInt32Memory0()[retptr / 4 + 2];
1620
+ var r3 = getInt32Memory0()[retptr / 4 + 3];
1621
+ if (r3) {
1622
+ throw takeObject(r2);
1623
+ }
1624
+ var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
1625
+ wasm.__wbindgen_free(r0, r1 * 4, 4);
1626
+ return v1;
1627
+ } finally {
1628
+ wasm.__wbindgen_add_to_stack_pointer(16);
1629
+ }
1630
+ }
1631
+ /**
1518
1632
  * @returns {any}
1519
1633
  */
1520
1634
  parse() {
@@ -1532,6 +1646,56 @@ export class Query {
1532
1646
  wasm.__wbindgen_add_to_stack_pointer(16);
1533
1647
  }
1534
1648
  }
1649
+ /**
1650
+ * @param {any} query
1651
+ * @returns {any}
1652
+ */
1653
+ process_query(query) {
1654
+ try {
1655
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
1656
+ wasm.query_process_query(retptr, this.__wbg_ptr, addBorrowedObject(query));
1657
+ var r0 = getInt32Memory0()[retptr / 4 + 0];
1658
+ var r1 = getInt32Memory0()[retptr / 4 + 1];
1659
+ var r2 = getInt32Memory0()[retptr / 4 + 2];
1660
+ if (r2) {
1661
+ throw takeObject(r1);
1662
+ }
1663
+ return takeObject(r0);
1664
+ } finally {
1665
+ wasm.__wbindgen_add_to_stack_pointer(16);
1666
+ heap[stack_pointer++] = undefined;
1667
+ }
1668
+ }
1669
+ /**
1670
+ * Returns the value of a property from the (normalized) query by its name.
1671
+ * This will scan the normalized query structure (including arrays, $and/$or blocks, etc.)
1672
+ * to find the first occurrence of the given property name and return its corresponding value.
1673
+ *
1674
+ * If not found, an error is returned.
1675
+ *
1676
+ * Example:
1677
+ * let val = query.get("age")?;
1678
+ * // val is a JsValue that might be a number, string, boolean, array, or object (e.g., { "$gt": 30 })
1679
+ * @param {string} property_name
1680
+ * @returns {any}
1681
+ */
1682
+ get(property_name) {
1683
+ try {
1684
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
1685
+ const ptr0 = passStringToWasm0(property_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
1686
+ const len0 = WASM_VECTOR_LEN;
1687
+ wasm.query_get(retptr, this.__wbg_ptr, ptr0, len0);
1688
+ var r0 = getInt32Memory0()[retptr / 4 + 0];
1689
+ var r1 = getInt32Memory0()[retptr / 4 + 1];
1690
+ var r2 = getInt32Memory0()[retptr / 4 + 2];
1691
+ if (r2) {
1692
+ throw takeObject(r1);
1693
+ }
1694
+ return takeObject(r0);
1695
+ } finally {
1696
+ wasm.__wbindgen_add_to_stack_pointer(16);
1697
+ }
1698
+ }
1535
1699
  }
1536
1700
 
1537
1701
  const SchemaFinalization = (typeof FinalizationRegistry === 'undefined')
@@ -1853,6 +2017,14 @@ function __wbg_get_imports() {
1853
2017
  imports.wbg.__wbindgen_object_drop_ref = function(arg0) {
1854
2018
  takeObject(arg0);
1855
2019
  };
2020
+ imports.wbg.__wbg_find_567c5c9f064fe3d2 = function() { return handleError(function (arg0, arg1, arg2, arg3) {
2021
+ const ret = getObject(arg0).find(getStringFromWasm0(arg1, arg2), takeObject(arg3));
2022
+ return addHeapObject(ret);
2023
+ }, arguments) };
2024
+ imports.wbg.__wbindgen_object_clone_ref = function(arg0) {
2025
+ const ret = getObject(arg0);
2026
+ return addHeapObject(ret);
2027
+ };
1856
2028
  imports.wbg.__wbindgen_is_undefined = function(arg0) {
1857
2029
  const ret = getObject(arg0) === undefined;
1858
2030
  return ret;
@@ -1865,37 +2037,14 @@ function __wbg_get_imports() {
1865
2037
  const ret = getStringFromWasm0(arg0, arg1);
1866
2038
  return addHeapObject(ret);
1867
2039
  };
1868
- imports.wbg.__wbindgen_object_clone_ref = function(arg0) {
1869
- const ret = getObject(arg0);
1870
- return addHeapObject(ret);
1871
- };
1872
- imports.wbg.__wbg_close_b18eee4bcb7def21 = function() { return handleError(function (arg0) {
1873
- const ret = getObject(arg0).close();
1874
- return addHeapObject(ret);
1875
- }, arguments) };
1876
- imports.wbg.__wbg_count_431f5e9ed174125c = function() { return handleError(function (arg0, arg1, arg2, arg3) {
1877
- const ret = getObject(arg0).count(getStringFromWasm0(arg1, arg2), takeObject(arg3));
1878
- return addHeapObject(ret);
1879
- }, arguments) };
1880
- imports.wbg.__wbg_indexdb_new = function(arg0) {
1881
- const ret = IndexDB.__wrap(arg0);
1882
- return addHeapObject(ret);
1883
- };
1884
- imports.wbg.__wbg_start_65a59f7936d1615b = function() { return handleError(function (arg0) {
1885
- const ret = getObject(arg0).start();
1886
- return addHeapObject(ret);
1887
- }, arguments) };
1888
2040
  imports.wbg.__wbg_inmemory_new = function(arg0) {
1889
2041
  const ret = InMemory.__wrap(arg0);
1890
2042
  return addHeapObject(ret);
1891
2043
  };
1892
- imports.wbg.__wbg_apply_69a38b2b812c92ba = function() { return handleError(function (arg0, arg1, arg2) {
1893
- const ret = getObject(arg1).apply(takeObject(arg2));
1894
- const ptr1 = passArrayJsValueToWasm0(ret, wasm.__wbindgen_malloc);
1895
- const len1 = WASM_VECTOR_LEN;
1896
- getInt32Memory0()[arg0 / 4 + 1] = len1;
1897
- getInt32Memory0()[arg0 / 4 + 0] = ptr1;
1898
- }, arguments) };
2044
+ imports.wbg.__wbindgen_number_new = function(arg0) {
2045
+ const ret = arg0;
2046
+ return addHeapObject(ret);
2047
+ };
1899
2048
  imports.wbg.__wbindgen_string_get = function(arg0, arg1) {
1900
2049
  const obj = getObject(arg1);
1901
2050
  const ret = typeof(obj) === 'string' ? obj : undefined;
@@ -1904,46 +2053,53 @@ function __wbg_get_imports() {
1904
2053
  getInt32Memory0()[arg0 / 4 + 1] = len1;
1905
2054
  getInt32Memory0()[arg0 / 4 + 0] = ptr1;
1906
2055
  };
1907
- imports.wbg.__wbindgen_number_new = function(arg0) {
1908
- const ret = arg0;
1909
- return addHeapObject(ret);
1910
- };
1911
- imports.wbg.__wbg_database_new = function(arg0) {
1912
- const ret = Database.__wrap(arg0);
2056
+ imports.wbg.__wbg_indexdb_new = function(arg0) {
2057
+ const ret = IndexDB.__wrap(arg0);
1913
2058
  return addHeapObject(ret);
1914
2059
  };
1915
- imports.wbg.__wbg_write_ca9bab98548a9017 = function() { return handleError(function (arg0, arg1) {
1916
- const ret = getObject(arg0).write(Operation.__wrap(arg1));
2060
+ imports.wbg.__wbg_count_19db4c3174d573d5 = function() { return handleError(function (arg0, arg1, arg2, arg3) {
2061
+ const ret = getObject(arg0).count(getStringFromWasm0(arg1, arg2), takeObject(arg3));
1917
2062
  return addHeapObject(ret);
1918
2063
  }, arguments) };
1919
- imports.wbg.__wbg_find_f9ccdf6abdbe1b6b = function() { return handleError(function (arg0, arg1, arg2, arg3) {
1920
- const ret = getObject(arg0).find(getStringFromWasm0(arg1, arg2), takeObject(arg3));
2064
+ imports.wbg.__wbg_close_6384ed3c27ef25c1 = function() { return handleError(function (arg0) {
2065
+ const ret = getObject(arg0).close();
1921
2066
  return addHeapObject(ret);
1922
2067
  }, arguments) };
1923
- imports.wbg.__wbg_findDocumentById_709034599222e0b9 = function() { return handleError(function (arg0, arg1, arg2, arg3) {
1924
- const ret = getObject(arg0).findDocumentById(getStringFromWasm0(arg1, arg2), takeObject(arg3));
2068
+ imports.wbg.__wbg_start_76c138c3b73ae6f8 = function() { return handleError(function (arg0) {
2069
+ const ret = getObject(arg0).start();
1925
2070
  return addHeapObject(ret);
1926
2071
  }, arguments) };
2072
+ imports.wbg.__wbg_apply_9f557eba1534d597 = function() { return handleError(function (arg0, arg1, arg2) {
2073
+ const ret = getObject(arg1).apply(takeObject(arg2));
2074
+ const ptr1 = passArrayJsValueToWasm0(ret, wasm.__wbindgen_malloc);
2075
+ const len1 = WASM_VECTOR_LEN;
2076
+ getInt32Memory0()[arg0 / 4 + 1] = len1;
2077
+ getInt32Memory0()[arg0 / 4 + 0] = ptr1;
2078
+ }, arguments) };
2079
+ imports.wbg.__wbg_database_new = function(arg0) {
2080
+ const ret = Database.__wrap(arg0);
2081
+ return addHeapObject(ret);
2082
+ };
1927
2083
  imports.wbg.__wbindgen_number_get = function(arg0, arg1) {
1928
2084
  const obj = getObject(arg1);
1929
2085
  const ret = typeof(obj) === 'number' ? obj : undefined;
1930
2086
  getFloat64Memory0()[arg0 / 8 + 1] = isLikeNone(ret) ? 0 : ret;
1931
2087
  getInt32Memory0()[arg0 / 4 + 0] = !isLikeNone(ret);
1932
2088
  };
1933
- imports.wbg.__wbindgen_error_new = function(arg0, arg1) {
1934
- const ret = new Error(getStringFromWasm0(arg0, arg1));
2089
+ imports.wbg.__wbg_findDocumentById_2edf7350e5f12657 = function() { return handleError(function (arg0, arg1, arg2, arg3) {
2090
+ const ret = getObject(arg0).findDocumentById(getStringFromWasm0(arg1, arg2), takeObject(arg3));
2091
+ return addHeapObject(ret);
2092
+ }, arguments) };
2093
+ imports.wbg.__wbg_write_1159c67c07f62020 = function() { return handleError(function (arg0, arg1) {
2094
+ const ret = getObject(arg0).write(Operation.__wrap(arg1));
2095
+ return addHeapObject(ret);
2096
+ }, arguments) };
2097
+ imports.wbg.__wbg_collection_new = function(arg0) {
2098
+ const ret = Collection.__wrap(arg0);
1935
2099
  return addHeapObject(ret);
1936
2100
  };
1937
- imports.wbg.__wbindgen_is_function = function(arg0) {
1938
- const ret = typeof(getObject(arg0)) === 'function';
1939
- return ret;
1940
- };
1941
- imports.wbg.__wbindgen_is_string = function(arg0) {
1942
- const ret = typeof(getObject(arg0)) === 'string';
1943
- return ret;
1944
- };
1945
- imports.wbg.__wbindgen_is_bigint = function(arg0) {
1946
- const ret = typeof(getObject(arg0)) === 'bigint';
2101
+ imports.wbg.__wbindgen_is_array = function(arg0) {
2102
+ const ret = Array.isArray(getObject(arg0));
1947
2103
  return ret;
1948
2104
  };
1949
2105
  imports.wbg.__wbindgen_is_object = function(arg0) {
@@ -1951,18 +2107,25 @@ function __wbg_get_imports() {
1951
2107
  const ret = typeof(val) === 'object' && val !== null;
1952
2108
  return ret;
1953
2109
  };
2110
+ imports.wbg.__wbindgen_is_string = function(arg0) {
2111
+ const ret = typeof(getObject(arg0)) === 'string';
2112
+ return ret;
2113
+ };
1954
2114
  imports.wbg.__wbindgen_is_falsy = function(arg0) {
1955
2115
  const ret = !getObject(arg0);
1956
2116
  return ret;
1957
2117
  };
1958
- imports.wbg.__wbindgen_boolean_get = function(arg0) {
1959
- const v = getObject(arg0);
1960
- const ret = typeof(v) === 'boolean' ? (v ? 1 : 0) : 2;
2118
+ imports.wbg.__wbindgen_error_new = function(arg0, arg1) {
2119
+ const ret = new Error(getStringFromWasm0(arg0, arg1));
2120
+ return addHeapObject(ret);
2121
+ };
2122
+ imports.wbg.__wbindgen_is_function = function(arg0) {
2123
+ const ret = typeof(getObject(arg0)) === 'function';
1961
2124
  return ret;
1962
2125
  };
1963
- imports.wbg.__wbg_collection_new = function(arg0) {
1964
- const ret = Collection.__wrap(arg0);
1965
- return addHeapObject(ret);
2126
+ imports.wbg.__wbindgen_is_bigint = function(arg0) {
2127
+ const ret = typeof(getObject(arg0)) === 'bigint';
2128
+ return ret;
1966
2129
  };
1967
2130
  imports.wbg.__wbindgen_cb_drop = function(arg0) {
1968
2131
  const obj = takeObject(arg0).original;
@@ -1973,8 +2136,9 @@ function __wbg_get_imports() {
1973
2136
  const ret = false;
1974
2137
  return ret;
1975
2138
  };
1976
- imports.wbg.__wbindgen_is_array = function(arg0) {
1977
- const ret = Array.isArray(getObject(arg0));
2139
+ imports.wbg.__wbindgen_boolean_get = function(arg0) {
2140
+ const v = getObject(arg0);
2141
+ const ret = typeof(v) === 'boolean' ? (v ? 1 : 0) : 2;
1978
2142
  return ret;
1979
2143
  };
1980
2144
  imports.wbg.__wbindgen_in = function(arg0, arg1) {
@@ -2041,23 +2205,25 @@ function __wbg_get_imports() {
2041
2205
  const ret = getObject(arg0).indexedDB;
2042
2206
  return isLikeNone(ret) ? 0 : addHeapObject(ret);
2043
2207
  }, arguments) };
2044
- imports.wbg.__wbg_getItem_164e8e5265095b87 = function() { return handleError(function (arg0, arg1, arg2, arg3) {
2045
- const ret = getObject(arg1).getItem(getStringFromWasm0(arg2, arg3));
2208
+ imports.wbg.__wbg_length_9ae5daf9a690cba9 = function(arg0) {
2209
+ const ret = getObject(arg0).length;
2210
+ return ret;
2211
+ };
2212
+ imports.wbg.__wbg_contains_c65b44400b549286 = function(arg0, arg1, arg2) {
2213
+ const ret = getObject(arg0).contains(getStringFromWasm0(arg1, arg2));
2214
+ return ret;
2215
+ };
2216
+ imports.wbg.__wbg_get_910bbb94abdcf488 = function(arg0, arg1, arg2) {
2217
+ const ret = getObject(arg1)[arg2 >>> 0];
2046
2218
  var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
2047
2219
  var len1 = WASM_VECTOR_LEN;
2048
2220
  getInt32Memory0()[arg0 / 4 + 1] = len1;
2049
2221
  getInt32Memory0()[arg0 / 4 + 0] = ptr1;
2050
- }, arguments) };
2051
- imports.wbg.__wbg_error_8e3928cfb8a43e2b = function(arg0) {
2052
- console.error(getObject(arg0));
2053
2222
  };
2054
- imports.wbg.__wbg_log_5bb5f88f245d7762 = function(arg0) {
2055
- console.log(getObject(arg0));
2223
+ imports.wbg.__wbg_target_2fc177e386c8b7b0 = function(arg0) {
2224
+ const ret = getObject(arg0).target;
2225
+ return isLikeNone(ret) ? 0 : addHeapObject(ret);
2056
2226
  };
2057
- imports.wbg.__wbg_open_f0d7259fd7e689ce = function() { return handleError(function (arg0, arg1, arg2, arg3) {
2058
- const ret = getObject(arg0).open(getStringFromWasm0(arg1, arg2), arg3 >>> 0);
2059
- return addHeapObject(ret);
2060
- }, arguments) };
2061
2227
  imports.wbg.__wbg_instanceof_IdbOpenDbRequest_3f4a166bc0340578 = function(arg0) {
2062
2228
  let result;
2063
2229
  try {
@@ -2105,25 +2271,48 @@ function __wbg_get_imports() {
2105
2271
  const ret = getObject(arg0).objectStore(getStringFromWasm0(arg1, arg2));
2106
2272
  return addHeapObject(ret);
2107
2273
  }, arguments) };
2108
- imports.wbg.__wbg_length_9ae5daf9a690cba9 = function(arg0) {
2109
- const ret = getObject(arg0).length;
2110
- return ret;
2111
- };
2112
- imports.wbg.__wbg_contains_c65b44400b549286 = function(arg0, arg1, arg2) {
2113
- const ret = getObject(arg0).contains(getStringFromWasm0(arg1, arg2));
2114
- return ret;
2274
+ imports.wbg.__wbg_log_5bb5f88f245d7762 = function(arg0) {
2275
+ console.log(getObject(arg0));
2115
2276
  };
2116
- imports.wbg.__wbg_get_910bbb94abdcf488 = function(arg0, arg1, arg2) {
2117
- const ret = getObject(arg1)[arg2 >>> 0];
2277
+ imports.wbg.__wbg_open_f0d7259fd7e689ce = function() { return handleError(function (arg0, arg1, arg2, arg3) {
2278
+ const ret = getObject(arg0).open(getStringFromWasm0(arg1, arg2), arg3 >>> 0);
2279
+ return addHeapObject(ret);
2280
+ }, arguments) };
2281
+ imports.wbg.__wbg_getAll_0ab46ba1dfcee129 = function() { return handleError(function (arg0, arg1) {
2282
+ const ret = getObject(arg0).getAll(getObject(arg1));
2283
+ return addHeapObject(ret);
2284
+ }, arguments) };
2285
+ imports.wbg.__wbg_getItem_164e8e5265095b87 = function() { return handleError(function (arg0, arg1, arg2, arg3) {
2286
+ const ret = getObject(arg1).getItem(getStringFromWasm0(arg2, arg3));
2118
2287
  var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
2119
2288
  var len1 = WASM_VECTOR_LEN;
2120
2289
  getInt32Memory0()[arg0 / 4 + 1] = len1;
2121
2290
  getInt32Memory0()[arg0 / 4 + 0] = ptr1;
2122
- };
2123
- imports.wbg.__wbg_target_2fc177e386c8b7b0 = function(arg0) {
2124
- const ret = getObject(arg0).target;
2125
- return isLikeNone(ret) ? 0 : addHeapObject(ret);
2126
- };
2291
+ }, arguments) };
2292
+ imports.wbg.__wbg_createIndex_b8da1f5571f644be = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4, arg5) {
2293
+ const ret = getObject(arg0).createIndex(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4), getObject(arg5));
2294
+ return addHeapObject(ret);
2295
+ }, arguments) };
2296
+ imports.wbg.__wbg_delete_f60bba7d0ae59a4f = function() { return handleError(function (arg0, arg1) {
2297
+ const ret = getObject(arg0).delete(getObject(arg1));
2298
+ return addHeapObject(ret);
2299
+ }, arguments) };
2300
+ imports.wbg.__wbg_get_5361b64cac0d0826 = function() { return handleError(function (arg0, arg1) {
2301
+ const ret = getObject(arg0).get(getObject(arg1));
2302
+ return addHeapObject(ret);
2303
+ }, arguments) };
2304
+ imports.wbg.__wbg_getAll_2782e438df699384 = function() { return handleError(function (arg0) {
2305
+ const ret = getObject(arg0).getAll();
2306
+ return addHeapObject(ret);
2307
+ }, arguments) };
2308
+ imports.wbg.__wbg_index_383b6812c1508030 = function() { return handleError(function (arg0, arg1, arg2) {
2309
+ const ret = getObject(arg0).index(getStringFromWasm0(arg1, arg2));
2310
+ return addHeapObject(ret);
2311
+ }, arguments) };
2312
+ imports.wbg.__wbg_put_22792e17580ca18b = function() { return handleError(function (arg0, arg1, arg2) {
2313
+ const ret = getObject(arg0).put(getObject(arg1), getObject(arg2));
2314
+ return addHeapObject(ret);
2315
+ }, arguments) };
2127
2316
  imports.wbg.__wbg_instanceof_IdbDatabase_db671cf2454a9542 = function(arg0) {
2128
2317
  let result;
2129
2318
  try {
@@ -2153,22 +2342,6 @@ function __wbg_get_imports() {
2153
2342
  const ret = getObject(arg0).transaction(getStringFromWasm0(arg1, arg2), takeObject(arg3));
2154
2343
  return addHeapObject(ret);
2155
2344
  }, arguments) };
2156
- imports.wbg.__wbg_delete_f60bba7d0ae59a4f = function() { return handleError(function (arg0, arg1) {
2157
- const ret = getObject(arg0).delete(getObject(arg1));
2158
- return addHeapObject(ret);
2159
- }, arguments) };
2160
- imports.wbg.__wbg_get_5361b64cac0d0826 = function() { return handleError(function (arg0, arg1) {
2161
- const ret = getObject(arg0).get(getObject(arg1));
2162
- return addHeapObject(ret);
2163
- }, arguments) };
2164
- imports.wbg.__wbg_getAll_2782e438df699384 = function() { return handleError(function (arg0) {
2165
- const ret = getObject(arg0).getAll();
2166
- return addHeapObject(ret);
2167
- }, arguments) };
2168
- imports.wbg.__wbg_put_22792e17580ca18b = function() { return handleError(function (arg0, arg1, arg2) {
2169
- const ret = getObject(arg0).put(getObject(arg1), getObject(arg2));
2170
- return addHeapObject(ret);
2171
- }, arguments) };
2172
2345
  imports.wbg.__wbindgen_jsval_loose_eq = function(arg0, arg1) {
2173
2346
  const ret = getObject(arg0) == getObject(arg1);
2174
2347
  return ret;
@@ -2215,7 +2388,7 @@ function __wbg_get_imports() {
2215
2388
  const a = state0.a;
2216
2389
  state0.a = 0;
2217
2390
  try {
2218
- return __wbg_adapter_253(a, state0.b, );
2391
+ return __wbg_adapter_265(a, state0.b, );
2219
2392
  } finally {
2220
2393
  state0.a = a;
2221
2394
  }
@@ -2225,6 +2398,13 @@ function __wbg_get_imports() {
2225
2398
  state0.a = state0.b = 0;
2226
2399
  }
2227
2400
  }, arguments) };
2401
+ imports.wbg.__wbg_wbgtestoutputwriteln_4db3bd64914ec955 = function(arg0) {
2402
+ __wbg_test_output_writeln(takeObject(arg0));
2403
+ };
2404
+ imports.wbg.__wbg_stack_436273c21658169b = function(arg0) {
2405
+ const ret = getObject(arg0).stack;
2406
+ return addHeapObject(ret);
2407
+ };
2228
2408
  imports.wbg.__wbg_static_accessor_document_d4b6ae7f5578480f = function() {
2229
2409
  const ret = document;
2230
2410
  return addHeapObject(ret);
@@ -2262,13 +2442,6 @@ function __wbg_get_imports() {
2262
2442
  const ret = getObject(arg0).stack;
2263
2443
  return addHeapObject(ret);
2264
2444
  };
2265
- imports.wbg.__wbg_wbgtestoutputwriteln_4db3bd64914ec955 = function(arg0) {
2266
- __wbg_test_output_writeln(takeObject(arg0));
2267
- };
2268
- imports.wbg.__wbg_stack_436273c21658169b = function(arg0) {
2269
- const ret = getObject(arg0).stack;
2270
- return addHeapObject(ret);
2271
- };
2272
2445
  imports.wbg.__wbg_new_abda76e883ba8a5f = function() {
2273
2446
  const ret = new Error();
2274
2447
  return addHeapObject(ret);
@@ -2380,7 +2553,7 @@ function __wbg_get_imports() {
2380
2553
  const a = state0.a;
2381
2554
  state0.a = 0;
2382
2555
  try {
2383
- return __wbg_adapter_296(a, state0.b, arg0, arg1, arg2);
2556
+ return __wbg_adapter_308(a, state0.b, arg0, arg1, arg2);
2384
2557
  } finally {
2385
2558
  state0.a = a;
2386
2559
  }
@@ -2463,7 +2636,7 @@ function __wbg_get_imports() {
2463
2636
  const a = state0.a;
2464
2637
  state0.a = 0;
2465
2638
  try {
2466
- return __wbg_adapter_349(a, state0.b, arg0, arg1);
2639
+ return __wbg_adapter_361(a, state0.b, arg0, arg1);
2467
2640
  } finally {
2468
2641
  state0.a = a;
2469
2642
  }
@@ -2563,24 +2736,24 @@ function __wbg_get_imports() {
2563
2736
  const ret = wasm.memory;
2564
2737
  return addHeapObject(ret);
2565
2738
  };
2566
- imports.wbg.__wbindgen_closure_wrapper567 = function(arg0, arg1, arg2) {
2567
- const ret = makeMutClosure(arg0, arg1, 241, __wbg_adapter_56);
2739
+ imports.wbg.__wbindgen_closure_wrapper524 = function(arg0, arg1, arg2) {
2740
+ const ret = makeClosure(arg0, arg1, 166, __wbg_adapter_56);
2568
2741
  return addHeapObject(ret);
2569
2742
  };
2570
- imports.wbg.__wbindgen_closure_wrapper569 = function(arg0, arg1, arg2) {
2571
- const ret = makeMutClosure(arg0, arg1, 241, __wbg_adapter_56);
2743
+ imports.wbg.__wbindgen_closure_wrapper526 = function(arg0, arg1, arg2) {
2744
+ const ret = makeMutClosure(arg0, arg1, 166, __wbg_adapter_59);
2572
2745
  return addHeapObject(ret);
2573
2746
  };
2574
- imports.wbg.__wbindgen_closure_wrapper571 = function(arg0, arg1, arg2) {
2575
- const ret = makeMutClosure(arg0, arg1, 241, __wbg_adapter_61);
2747
+ imports.wbg.__wbindgen_closure_wrapper528 = function(arg0, arg1, arg2) {
2748
+ const ret = makeMutClosure(arg0, arg1, 166, __wbg_adapter_59);
2576
2749
  return addHeapObject(ret);
2577
2750
  };
2578
- imports.wbg.__wbindgen_closure_wrapper573 = function(arg0, arg1, arg2) {
2579
- const ret = makeClosure(arg0, arg1, 241, __wbg_adapter_64);
2751
+ imports.wbg.__wbindgen_closure_wrapper530 = function(arg0, arg1, arg2) {
2752
+ const ret = makeMutClosure(arg0, arg1, 166, __wbg_adapter_64);
2580
2753
  return addHeapObject(ret);
2581
2754
  };
2582
- imports.wbg.__wbindgen_closure_wrapper1374 = function(arg0, arg1, arg2) {
2583
- const ret = makeMutClosure(arg0, arg1, 375, __wbg_adapter_67);
2755
+ imports.wbg.__wbindgen_closure_wrapper1511 = function(arg0, arg1, arg2) {
2756
+ const ret = makeMutClosure(arg0, arg1, 420, __wbg_adapter_67);
2584
2757
  return addHeapObject(ret);
2585
2758
  };
2586
2759