@loradb/lora-wasm 0.1.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.
Files changed (49) hide show
  1. package/LICENSE +87 -0
  2. package/README.md +197 -0
  3. package/dist/index.d.ts +66 -0
  4. package/dist/index.d.ts.map +1 -0
  5. package/dist/index.js +87 -0
  6. package/dist/index.js.map +1 -0
  7. package/dist/loader-node.d.ts +12 -0
  8. package/dist/loader-node.d.ts.map +1 -0
  9. package/dist/loader-node.js +12 -0
  10. package/dist/loader-node.js.map +1 -0
  11. package/dist/types.d.ts +193 -0
  12. package/dist/types.d.ts.map +1 -0
  13. package/dist/types.js +111 -0
  14. package/dist/types.js.map +1 -0
  15. package/dist/worker-client.d.ts +41 -0
  16. package/dist/worker-client.d.ts.map +1 -0
  17. package/dist/worker-client.js +69 -0
  18. package/dist/worker-client.js.map +1 -0
  19. package/dist/worker-protocol.d.ts +40 -0
  20. package/dist/worker-protocol.d.ts.map +1 -0
  21. package/dist/worker-protocol.js +9 -0
  22. package/dist/worker-protocol.js.map +1 -0
  23. package/dist/worker.d.ts +12 -0
  24. package/dist/worker.d.ts.map +1 -0
  25. package/dist/worker.js +75 -0
  26. package/dist/worker.js.map +1 -0
  27. package/package.json +98 -0
  28. package/pkg-bundler/LICENSE +87 -0
  29. package/pkg-bundler/README.md +197 -0
  30. package/pkg-bundler/lora_wasm.d.ts +25 -0
  31. package/pkg-bundler/lora_wasm.js +5 -0
  32. package/pkg-bundler/lora_wasm_bg.js +559 -0
  33. package/pkg-bundler/lora_wasm_bg.wasm +0 -0
  34. package/pkg-bundler/lora_wasm_bg.wasm.d.ts +18 -0
  35. package/pkg-bundler/package.json +22 -0
  36. package/pkg-node/LICENSE +87 -0
  37. package/pkg-node/README.md +197 -0
  38. package/pkg-node/lora_wasm.d.ts +25 -0
  39. package/pkg-node/lora_wasm.js +566 -0
  40. package/pkg-node/lora_wasm_bg.wasm +0 -0
  41. package/pkg-node/lora_wasm_bg.wasm.d.ts +18 -0
  42. package/pkg-node/package.json +16 -0
  43. package/pkg-web/LICENSE +87 -0
  44. package/pkg-web/README.md +197 -0
  45. package/pkg-web/lora_wasm.d.ts +67 -0
  46. package/pkg-web/lora_wasm.js +607 -0
  47. package/pkg-web/lora_wasm_bg.wasm +0 -0
  48. package/pkg-web/lora_wasm_bg.wasm.d.ts +18 -0
  49. package/pkg-web/package.json +20 -0
@@ -0,0 +1,559 @@
1
+ let wasm;
2
+ export function __wbg_set_wasm(val) {
3
+ wasm = val;
4
+ }
5
+
6
+
7
+ let WASM_VECTOR_LEN = 0;
8
+
9
+ let cachedUint8ArrayMemory0 = null;
10
+
11
+ function getUint8ArrayMemory0() {
12
+ if (cachedUint8ArrayMemory0 === null || cachedUint8ArrayMemory0.byteLength === 0) {
13
+ cachedUint8ArrayMemory0 = new Uint8Array(wasm.memory.buffer);
14
+ }
15
+ return cachedUint8ArrayMemory0;
16
+ }
17
+
18
+ const lTextEncoder = typeof TextEncoder === 'undefined' ? (0, module.require)('util').TextEncoder : TextEncoder;
19
+
20
+ let cachedTextEncoder = new lTextEncoder('utf-8');
21
+
22
+ const encodeString = (typeof cachedTextEncoder.encodeInto === 'function'
23
+ ? function (arg, view) {
24
+ return cachedTextEncoder.encodeInto(arg, view);
25
+ }
26
+ : function (arg, view) {
27
+ const buf = cachedTextEncoder.encode(arg);
28
+ view.set(buf);
29
+ return {
30
+ read: arg.length,
31
+ written: buf.length
32
+ };
33
+ });
34
+
35
+ function passStringToWasm0(arg, malloc, realloc) {
36
+
37
+ if (realloc === undefined) {
38
+ const buf = cachedTextEncoder.encode(arg);
39
+ const ptr = malloc(buf.length, 1) >>> 0;
40
+ getUint8ArrayMemory0().subarray(ptr, ptr + buf.length).set(buf);
41
+ WASM_VECTOR_LEN = buf.length;
42
+ return ptr;
43
+ }
44
+
45
+ let len = arg.length;
46
+ let ptr = malloc(len, 1) >>> 0;
47
+
48
+ const mem = getUint8ArrayMemory0();
49
+
50
+ let offset = 0;
51
+
52
+ for (; offset < len; offset++) {
53
+ const code = arg.charCodeAt(offset);
54
+ if (code > 0x7F) break;
55
+ mem[ptr + offset] = code;
56
+ }
57
+
58
+ if (offset !== len) {
59
+ if (offset !== 0) {
60
+ arg = arg.slice(offset);
61
+ }
62
+ ptr = realloc(ptr, len, len = offset + arg.length * 3, 1) >>> 0;
63
+ const view = getUint8ArrayMemory0().subarray(ptr + offset, ptr + len);
64
+ const ret = encodeString(arg, view);
65
+
66
+ offset += ret.written;
67
+ ptr = realloc(ptr, len, offset, 1) >>> 0;
68
+ }
69
+
70
+ WASM_VECTOR_LEN = offset;
71
+ return ptr;
72
+ }
73
+
74
+ let cachedDataViewMemory0 = null;
75
+
76
+ function getDataViewMemory0() {
77
+ if (cachedDataViewMemory0 === null || cachedDataViewMemory0.buffer.detached === true || (cachedDataViewMemory0.buffer.detached === undefined && cachedDataViewMemory0.buffer !== wasm.memory.buffer)) {
78
+ cachedDataViewMemory0 = new DataView(wasm.memory.buffer);
79
+ }
80
+ return cachedDataViewMemory0;
81
+ }
82
+
83
+ function addToExternrefTable0(obj) {
84
+ const idx = wasm.__externref_table_alloc();
85
+ wasm.__wbindgen_export_4.set(idx, obj);
86
+ return idx;
87
+ }
88
+
89
+ function handleError(f, args) {
90
+ try {
91
+ return f.apply(this, args);
92
+ } catch (e) {
93
+ const idx = addToExternrefTable0(e);
94
+ wasm.__wbindgen_exn_store(idx);
95
+ }
96
+ }
97
+
98
+ const lTextDecoder = typeof TextDecoder === 'undefined' ? (0, module.require)('util').TextDecoder : TextDecoder;
99
+
100
+ let cachedTextDecoder = new lTextDecoder('utf-8', { ignoreBOM: true, fatal: true });
101
+
102
+ cachedTextDecoder.decode();
103
+
104
+ function getStringFromWasm0(ptr, len) {
105
+ ptr = ptr >>> 0;
106
+ return cachedTextDecoder.decode(getUint8ArrayMemory0().subarray(ptr, ptr + len));
107
+ }
108
+
109
+ function isLikeNone(x) {
110
+ return x === undefined || x === null;
111
+ }
112
+
113
+ function debugString(val) {
114
+ // primitive types
115
+ const type = typeof val;
116
+ if (type == 'number' || type == 'boolean' || val == null) {
117
+ return `${val}`;
118
+ }
119
+ if (type == 'string') {
120
+ return `"${val}"`;
121
+ }
122
+ if (type == 'symbol') {
123
+ const description = val.description;
124
+ if (description == null) {
125
+ return 'Symbol';
126
+ } else {
127
+ return `Symbol(${description})`;
128
+ }
129
+ }
130
+ if (type == 'function') {
131
+ const name = val.name;
132
+ if (typeof name == 'string' && name.length > 0) {
133
+ return `Function(${name})`;
134
+ } else {
135
+ return 'Function';
136
+ }
137
+ }
138
+ // objects
139
+ if (Array.isArray(val)) {
140
+ const length = val.length;
141
+ let debug = '[';
142
+ if (length > 0) {
143
+ debug += debugString(val[0]);
144
+ }
145
+ for(let i = 1; i < length; i++) {
146
+ debug += ', ' + debugString(val[i]);
147
+ }
148
+ debug += ']';
149
+ return debug;
150
+ }
151
+ // Test for built-in
152
+ const builtInMatches = /\[object ([^\]]+)\]/.exec(toString.call(val));
153
+ let className;
154
+ if (builtInMatches && builtInMatches.length > 1) {
155
+ className = builtInMatches[1];
156
+ } else {
157
+ // Failed to match the standard '[object ClassName]'
158
+ return toString.call(val);
159
+ }
160
+ if (className == 'Object') {
161
+ // we're a user defined class or Object
162
+ // JSON.stringify avoids problems with cycles, and is generally much
163
+ // easier than looping through ownProperties of `val`.
164
+ try {
165
+ return 'Object(' + JSON.stringify(val) + ')';
166
+ } catch (_) {
167
+ return 'Object';
168
+ }
169
+ }
170
+ // errors
171
+ if (val instanceof Error) {
172
+ return `${val.name}: ${val.message}\n${val.stack}`;
173
+ }
174
+ // TODO we could test for more things here, like `Set`s and `Map`s.
175
+ return className;
176
+ }
177
+
178
+ function takeFromExternrefTable0(idx) {
179
+ const value = wasm.__wbindgen_export_4.get(idx);
180
+ wasm.__externref_table_dealloc(idx);
181
+ return value;
182
+ }
183
+ /**
184
+ * Call once at module start to install a panic hook that routes Rust
185
+ * panics to `console.error`. No-op if compiled without the default feature.
186
+ */
187
+ export function init() {
188
+ wasm.init();
189
+ }
190
+
191
+ const WasmDatabaseFinalization = (typeof FinalizationRegistry === 'undefined')
192
+ ? { register: () => {}, unregister: () => {} }
193
+ : new FinalizationRegistry(ptr => wasm.__wbg_wasmdatabase_free(ptr >>> 0, 1));
194
+ /**
195
+ * In-memory Lora graph database handle.
196
+ */
197
+ export class WasmDatabase {
198
+
199
+ __destroy_into_raw() {
200
+ const ptr = this.__wbg_ptr;
201
+ this.__wbg_ptr = 0;
202
+ WasmDatabaseFinalization.unregister(this);
203
+ return ptr;
204
+ }
205
+
206
+ free() {
207
+ const ptr = this.__destroy_into_raw();
208
+ wasm.__wbg_wasmdatabase_free(ptr, 0);
209
+ }
210
+ /**
211
+ * @returns {number}
212
+ */
213
+ nodeCount() {
214
+ const ret = wasm.wasmdatabase_nodeCount(this.__wbg_ptr);
215
+ return ret >>> 0;
216
+ }
217
+ /**
218
+ * @returns {number}
219
+ */
220
+ relationshipCount() {
221
+ const ret = wasm.wasmdatabase_relationshipCount(this.__wbg_ptr);
222
+ return ret >>> 0;
223
+ }
224
+ constructor() {
225
+ const ret = wasm.wasmdatabase_new();
226
+ this.__wbg_ptr = ret >>> 0;
227
+ WasmDatabaseFinalization.register(this, this.__wbg_ptr, this);
228
+ return this;
229
+ }
230
+ clear() {
231
+ wasm.wasmdatabase_clear(this.__wbg_ptr);
232
+ }
233
+ /**
234
+ * Execute a Lora query. `params` may be `undefined`, `null`, or a
235
+ * plain object keyed by parameter name.
236
+ *
237
+ * Returns `{ columns: string[], rows: Array<Record<string, LoraValue>> }`
238
+ * as a plain JS object (structured-clonable).
239
+ * @param {string} query
240
+ * @param {any} params
241
+ * @returns {any}
242
+ */
243
+ execute(query, params) {
244
+ const ptr0 = passStringToWasm0(query, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
245
+ const len0 = WASM_VECTOR_LEN;
246
+ const ret = wasm.wasmdatabase_execute(this.__wbg_ptr, ptr0, len0, params);
247
+ if (ret[2]) {
248
+ throw takeFromExternrefTable0(ret[1]);
249
+ }
250
+ return takeFromExternrefTable0(ret[0]);
251
+ }
252
+ }
253
+
254
+ export function __wbg_String_8f0eb39a4a4c2f66(arg0, arg1) {
255
+ const ret = String(arg1);
256
+ const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
257
+ const len1 = WASM_VECTOR_LEN;
258
+ getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
259
+ getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
260
+ };
261
+
262
+ export function __wbg_buffer_609cc3eee51ed158(arg0) {
263
+ const ret = arg0.buffer;
264
+ return ret;
265
+ };
266
+
267
+ export function __wbg_call_672a4d21634d4a24() { return handleError(function (arg0, arg1) {
268
+ const ret = arg0.call(arg1);
269
+ return ret;
270
+ }, arguments) };
271
+
272
+ export function __wbg_done_769e5ede4b31c67b(arg0) {
273
+ const ret = arg0.done;
274
+ return ret;
275
+ };
276
+
277
+ export function __wbg_entries_3265d4158b33e5dc(arg0) {
278
+ const ret = Object.entries(arg0);
279
+ return ret;
280
+ };
281
+
282
+ export function __wbg_error_7534b8e9a36f1ab4(arg0, arg1) {
283
+ let deferred0_0;
284
+ let deferred0_1;
285
+ try {
286
+ deferred0_0 = arg0;
287
+ deferred0_1 = arg1;
288
+ console.error(getStringFromWasm0(arg0, arg1));
289
+ } finally {
290
+ wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
291
+ }
292
+ };
293
+
294
+ export function __wbg_get_67b2ba62fc30de12() { return handleError(function (arg0, arg1) {
295
+ const ret = Reflect.get(arg0, arg1);
296
+ return ret;
297
+ }, arguments) };
298
+
299
+ export function __wbg_get_b9b93047fe3cf45b(arg0, arg1) {
300
+ const ret = arg0[arg1 >>> 0];
301
+ return ret;
302
+ };
303
+
304
+ export function __wbg_instanceof_ArrayBuffer_e14585432e3737fc(arg0) {
305
+ let result;
306
+ try {
307
+ result = arg0 instanceof ArrayBuffer;
308
+ } catch (_) {
309
+ result = false;
310
+ }
311
+ const ret = result;
312
+ return ret;
313
+ };
314
+
315
+ export function __wbg_instanceof_Map_f3469ce2244d2430(arg0) {
316
+ let result;
317
+ try {
318
+ result = arg0 instanceof Map;
319
+ } catch (_) {
320
+ result = false;
321
+ }
322
+ const ret = result;
323
+ return ret;
324
+ };
325
+
326
+ export function __wbg_instanceof_Uint8Array_17156bcf118086a9(arg0) {
327
+ let result;
328
+ try {
329
+ result = arg0 instanceof Uint8Array;
330
+ } catch (_) {
331
+ result = false;
332
+ }
333
+ const ret = result;
334
+ return ret;
335
+ };
336
+
337
+ export function __wbg_isArray_a1eab7e0d067391b(arg0) {
338
+ const ret = Array.isArray(arg0);
339
+ return ret;
340
+ };
341
+
342
+ export function __wbg_isSafeInteger_343e2beeeece1bb0(arg0) {
343
+ const ret = Number.isSafeInteger(arg0);
344
+ return ret;
345
+ };
346
+
347
+ export function __wbg_iterator_9a24c88df860dc65() {
348
+ const ret = Symbol.iterator;
349
+ return ret;
350
+ };
351
+
352
+ export function __wbg_length_a446193dc22c12f8(arg0) {
353
+ const ret = arg0.length;
354
+ return ret;
355
+ };
356
+
357
+ export function __wbg_length_e2d2a49132c1b256(arg0) {
358
+ const ret = arg0.length;
359
+ return ret;
360
+ };
361
+
362
+ export function __wbg_new_405e22f390576ce2() {
363
+ const ret = new Object();
364
+ return ret;
365
+ };
366
+
367
+ export function __wbg_new_5e0be73521bc8c17() {
368
+ const ret = new Map();
369
+ return ret;
370
+ };
371
+
372
+ export function __wbg_new_78feb108b6472713() {
373
+ const ret = new Array();
374
+ return ret;
375
+ };
376
+
377
+ export function __wbg_new_8a6f238a6ece86ea() {
378
+ const ret = new Error();
379
+ return ret;
380
+ };
381
+
382
+ export function __wbg_new_a12002a7f91c75be(arg0) {
383
+ const ret = new Uint8Array(arg0);
384
+ return ret;
385
+ };
386
+
387
+ export function __wbg_next_25feadfc0913fea9(arg0) {
388
+ const ret = arg0.next;
389
+ return ret;
390
+ };
391
+
392
+ export function __wbg_next_6574e1a8a62d1055() { return handleError(function (arg0) {
393
+ const ret = arg0.next();
394
+ return ret;
395
+ }, arguments) };
396
+
397
+ export function __wbg_now_807e54c39636c349() {
398
+ const ret = Date.now();
399
+ return ret;
400
+ };
401
+
402
+ export function __wbg_set_37837023f3d740e8(arg0, arg1, arg2) {
403
+ arg0[arg1 >>> 0] = arg2;
404
+ };
405
+
406
+ export function __wbg_set_3f1d0b984ed272ed(arg0, arg1, arg2) {
407
+ arg0[arg1] = arg2;
408
+ };
409
+
410
+ export function __wbg_set_65595bdd868b3009(arg0, arg1, arg2) {
411
+ arg0.set(arg1, arg2 >>> 0);
412
+ };
413
+
414
+ export function __wbg_set_8fc6bf8a5b1071d1(arg0, arg1, arg2) {
415
+ const ret = arg0.set(arg1, arg2);
416
+ return ret;
417
+ };
418
+
419
+ export function __wbg_stack_0ed75d68575b0f3c(arg0, arg1) {
420
+ const ret = arg1.stack;
421
+ const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
422
+ const len1 = WASM_VECTOR_LEN;
423
+ getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
424
+ getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
425
+ };
426
+
427
+ export function __wbg_value_cd1ffa7b1ab794f1(arg0) {
428
+ const ret = arg0.value;
429
+ return ret;
430
+ };
431
+
432
+ export function __wbindgen_bigint_from_i64(arg0) {
433
+ const ret = arg0;
434
+ return ret;
435
+ };
436
+
437
+ export function __wbindgen_bigint_from_u64(arg0) {
438
+ const ret = BigInt.asUintN(64, arg0);
439
+ return ret;
440
+ };
441
+
442
+ export function __wbindgen_bigint_get_as_i64(arg0, arg1) {
443
+ const v = arg1;
444
+ const ret = typeof(v) === 'bigint' ? v : undefined;
445
+ getDataViewMemory0().setBigInt64(arg0 + 8 * 1, isLikeNone(ret) ? BigInt(0) : ret, true);
446
+ getDataViewMemory0().setInt32(arg0 + 4 * 0, !isLikeNone(ret), true);
447
+ };
448
+
449
+ export function __wbindgen_boolean_get(arg0) {
450
+ const v = arg0;
451
+ const ret = typeof(v) === 'boolean' ? (v ? 1 : 0) : 2;
452
+ return ret;
453
+ };
454
+
455
+ export function __wbindgen_debug_string(arg0, arg1) {
456
+ const ret = debugString(arg1);
457
+ const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
458
+ const len1 = WASM_VECTOR_LEN;
459
+ getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
460
+ getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
461
+ };
462
+
463
+ export function __wbindgen_error_new(arg0, arg1) {
464
+ const ret = new Error(getStringFromWasm0(arg0, arg1));
465
+ return ret;
466
+ };
467
+
468
+ export function __wbindgen_in(arg0, arg1) {
469
+ const ret = arg0 in arg1;
470
+ return ret;
471
+ };
472
+
473
+ export function __wbindgen_init_externref_table() {
474
+ const table = wasm.__wbindgen_export_4;
475
+ const offset = table.grow(4);
476
+ table.set(0, undefined);
477
+ table.set(offset + 0, undefined);
478
+ table.set(offset + 1, null);
479
+ table.set(offset + 2, true);
480
+ table.set(offset + 3, false);
481
+ ;
482
+ };
483
+
484
+ export function __wbindgen_is_bigint(arg0) {
485
+ const ret = typeof(arg0) === 'bigint';
486
+ return ret;
487
+ };
488
+
489
+ export function __wbindgen_is_function(arg0) {
490
+ const ret = typeof(arg0) === 'function';
491
+ return ret;
492
+ };
493
+
494
+ export function __wbindgen_is_null(arg0) {
495
+ const ret = arg0 === null;
496
+ return ret;
497
+ };
498
+
499
+ export function __wbindgen_is_object(arg0) {
500
+ const val = arg0;
501
+ const ret = typeof(val) === 'object' && val !== null;
502
+ return ret;
503
+ };
504
+
505
+ export function __wbindgen_is_string(arg0) {
506
+ const ret = typeof(arg0) === 'string';
507
+ return ret;
508
+ };
509
+
510
+ export function __wbindgen_is_undefined(arg0) {
511
+ const ret = arg0 === undefined;
512
+ return ret;
513
+ };
514
+
515
+ export function __wbindgen_jsval_eq(arg0, arg1) {
516
+ const ret = arg0 === arg1;
517
+ return ret;
518
+ };
519
+
520
+ export function __wbindgen_jsval_loose_eq(arg0, arg1) {
521
+ const ret = arg0 == arg1;
522
+ return ret;
523
+ };
524
+
525
+ export function __wbindgen_memory() {
526
+ const ret = wasm.memory;
527
+ return ret;
528
+ };
529
+
530
+ export function __wbindgen_number_get(arg0, arg1) {
531
+ const obj = arg1;
532
+ const ret = typeof(obj) === 'number' ? obj : undefined;
533
+ getDataViewMemory0().setFloat64(arg0 + 8 * 1, isLikeNone(ret) ? 0 : ret, true);
534
+ getDataViewMemory0().setInt32(arg0 + 4 * 0, !isLikeNone(ret), true);
535
+ };
536
+
537
+ export function __wbindgen_number_new(arg0) {
538
+ const ret = arg0;
539
+ return ret;
540
+ };
541
+
542
+ export function __wbindgen_string_get(arg0, arg1) {
543
+ const obj = arg1;
544
+ const ret = typeof(obj) === 'string' ? obj : undefined;
545
+ var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
546
+ var len1 = WASM_VECTOR_LEN;
547
+ getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
548
+ getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
549
+ };
550
+
551
+ export function __wbindgen_string_new(arg0, arg1) {
552
+ const ret = getStringFromWasm0(arg0, arg1);
553
+ return ret;
554
+ };
555
+
556
+ export function __wbindgen_throw(arg0, arg1) {
557
+ throw new Error(getStringFromWasm0(arg0, arg1));
558
+ };
559
+
Binary file
@@ -0,0 +1,18 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ export const memory: WebAssembly.Memory;
4
+ export const __wbg_wasmdatabase_free: (a: number, b: number) => void;
5
+ export const wasmdatabase_clear: (a: number) => void;
6
+ export const wasmdatabase_execute: (a: number, b: number, c: number, d: any) => [number, number, number];
7
+ export const wasmdatabase_new: () => number;
8
+ export const wasmdatabase_nodeCount: (a: number) => number;
9
+ export const wasmdatabase_relationshipCount: (a: number) => number;
10
+ export const init: () => void;
11
+ export const __wbindgen_malloc: (a: number, b: number) => number;
12
+ export const __wbindgen_realloc: (a: number, b: number, c: number, d: number) => number;
13
+ export const __wbindgen_exn_store: (a: number) => void;
14
+ export const __externref_table_alloc: () => number;
15
+ export const __wbindgen_export_4: WebAssembly.Table;
16
+ export const __wbindgen_free: (a: number, b: number, c: number) => void;
17
+ export const __externref_table_dealloc: (a: number) => void;
18
+ export const __wbindgen_start: () => void;
@@ -0,0 +1,22 @@
1
+ {
2
+ "name": "lora-wasm",
3
+ "type": "module",
4
+ "collaborators": [
5
+ "LoraDB, Inc."
6
+ ],
7
+ "description": "WebAssembly bindings for the Lora in-memory graph database",
8
+ "version": "0.1.0",
9
+ "license": "BUSL-1.1",
10
+ "files": [
11
+ "lora_wasm_bg.wasm",
12
+ "lora_wasm.js",
13
+ "lora_wasm_bg.js",
14
+ "lora_wasm.d.ts"
15
+ ],
16
+ "main": "lora_wasm.js",
17
+ "types": "lora_wasm.d.ts",
18
+ "sideEffects": [
19
+ "./lora_wasm.js",
20
+ "./snippets/*"
21
+ ]
22
+ }
@@ -0,0 +1,87 @@
1
+ Business Source License 1.1
2
+
3
+ Parameters
4
+
5
+ Licensor: LoraDB, Inc.
6
+ Licensed Work: LoraDB
7
+ Change Date: 2029-04-19
8
+ Change License: Apache License, Version 2.0
9
+
10
+ Additional Use Grant: You may use, copy, modify, create derivative works of,
11
+ distribute, and make production use of the Licensed Work
12
+ for internal business purposes and non-production
13
+ purposes, provided that you do not use the Licensed Work
14
+ to offer, operate, or make available a database-as-a-
15
+ service, hosted API, managed database platform, or any
16
+ substantially similar hosted service for third parties.
17
+
18
+ The Additional Use Grant does not permit using the
19
+ Licensed Work to provide a commercial or non-commercial
20
+ hosted service that allows third parties to access LoraDB
21
+ functionality, including as part of a competing managed
22
+ database platform, backend-as-a-service, application
23
+ platform, developer platform, or resale offering.
24
+
25
+ Business Source License
26
+
27
+ Terms
28
+
29
+ The Licensor hereby grants you the right to copy, modify, create derivative
30
+ works, redistribute, and make non-production use of the Licensed Work. The
31
+ Licensor may make an Additional Use Grant, above, permitting limited production
32
+ use.
33
+
34
+ Effective on the Change Date, or the fourth anniversary of the first publicly
35
+ available distribution of a specific version of the Licensed Work under this
36
+ License, whichever comes first, the Licensor hereby grants you rights under
37
+ the terms of the Change License, and the rights granted in the paragraph
38
+ above terminate.
39
+
40
+ If your use of the Licensed Work does not comply with the requirements
41
+ currently in effect as described in this License, you must purchase a
42
+ commercial license from the Licensor, its affiliated entities, or authorized
43
+ resellers, or you must refrain from using the Licensed Work.
44
+
45
+ All copies of the original and modified Licensed Work, and derivative works
46
+ of the Licensed Work, are subject to this License. This License applies
47
+ separately for each version of the Licensed Work and the Change Date may vary
48
+ for each version of the Licensed Work released by Licensor.
49
+
50
+ You must conspicuously display this License on each original or modified copy
51
+ of the Licensed Work. If you receive the Licensed Work in original or modified
52
+ form from a third party, the terms and conditions set forth in this License
53
+ apply to your use of that work.
54
+
55
+ Any use of the Licensed Work in violation of this License will automatically
56
+ terminate your rights under this License for the current and all other
57
+ versions of the Licensed Work.
58
+
59
+ This License does not grant you any right in any trademark or logo of Licensor
60
+ or its affiliates.
61
+
62
+ TO THE EXTENT PERMITTED BY APPLICABLE LAW, THE LICENSED WORK IS PROVIDED ON
63
+ AN "AS IS" BASIS. LICENSOR HEREBY DISCLAIMS ALL WARRANTIES AND CONDITIONS,
64
+ EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION WARRANTIES OF MERCHANTABILITY,
65
+ FITNESS FOR A PARTICULAR PURPOSE, NON-INFRINGEMENT, AND TITLE.
66
+
67
+ MariaDB hereby grants you permission to use this License's text to license
68
+ your works, and to refer to it using the trademark "Business Source License",
69
+ as long as you comply with the Covenants of Licensor below.
70
+
71
+ Covenants of Licensor
72
+
73
+ In consideration of the right to use this License's text and the "Business
74
+ Source License" name and trademark, Licensor covenants to MariaDB, and to all
75
+ other recipients of the licensed work to be provided by Licensor:
76
+
77
+ 1. To specify as the Change License the GPL Version 2.0 or any later version,
78
+ or a license that is compatible with GPL Version 2.0 or a later version,
79
+ where "compatible" means that software provided under the Change License can
80
+ be included in a program with software provided under GPL Version 2.0 or a
81
+ later version. Licensor may specify additional Change Licenses without
82
+ limitation.
83
+ 2. To either: (a) specify an additional grant of rights to use that does not
84
+ impose any additional restriction on the right granted in this License, as
85
+ the Additional Use Grant; or (b) insert the text "None".
86
+ 3. To specify a Change Date.
87
+ 4. Not to modify this License in any other way.