@xmtp/wasm-bindings 0.0.15 → 0.0.17
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/README.md +15 -2
- package/package.json +4 -5
- package/dist/bindings_wasm.d.ts +0 -732
- package/dist/bindings_wasm.js +0 -4525
- package/dist/bindings_wasm_bg.wasm +0 -0
- package/dist/bindings_wasm_bg.wasm.d.ts +0 -292
- package/dist/snippets/sqlite-web-90f8afa7b0cd2303/src/js/sqlite3-diesel.js +0 -1
- package/dist/snippets/sqlite-web-90f8afa7b0cd2303/src/js/sqlite3-opfs-async-proxy.js +0 -1
- package/dist/snippets/sqlite-web-90f8afa7b0cd2303/src/js/sqlite3.wasm +0 -0
package/dist/bindings_wasm.js
DELETED
|
@@ -1,4525 +0,0 @@
|
|
|
1
|
-
import { SQLite } from './snippets/sqlite-web-90f8afa7b0cd2303/src/js/sqlite3-diesel.js';
|
|
2
|
-
|
|
3
|
-
let wasm;
|
|
4
|
-
|
|
5
|
-
let WASM_VECTOR_LEN = 0;
|
|
6
|
-
|
|
7
|
-
let cachedUint8ArrayMemory0 = null;
|
|
8
|
-
|
|
9
|
-
function getUint8ArrayMemory0() {
|
|
10
|
-
if (cachedUint8ArrayMemory0 === null || cachedUint8ArrayMemory0.byteLength === 0) {
|
|
11
|
-
cachedUint8ArrayMemory0 = new Uint8Array(wasm.memory.buffer);
|
|
12
|
-
}
|
|
13
|
-
return cachedUint8ArrayMemory0;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
const cachedTextEncoder = (typeof TextEncoder !== 'undefined' ? new TextEncoder('utf-8') : { encode: () => { throw Error('TextEncoder not available') } } );
|
|
17
|
-
|
|
18
|
-
const encodeString = (typeof cachedTextEncoder.encodeInto === 'function'
|
|
19
|
-
? function (arg, view) {
|
|
20
|
-
return cachedTextEncoder.encodeInto(arg, view);
|
|
21
|
-
}
|
|
22
|
-
: function (arg, view) {
|
|
23
|
-
const buf = cachedTextEncoder.encode(arg);
|
|
24
|
-
view.set(buf);
|
|
25
|
-
return {
|
|
26
|
-
read: arg.length,
|
|
27
|
-
written: buf.length
|
|
28
|
-
};
|
|
29
|
-
});
|
|
30
|
-
|
|
31
|
-
function passStringToWasm0(arg, malloc, realloc) {
|
|
32
|
-
|
|
33
|
-
if (realloc === undefined) {
|
|
34
|
-
const buf = cachedTextEncoder.encode(arg);
|
|
35
|
-
const ptr = malloc(buf.length, 1) >>> 0;
|
|
36
|
-
getUint8ArrayMemory0().subarray(ptr, ptr + buf.length).set(buf);
|
|
37
|
-
WASM_VECTOR_LEN = buf.length;
|
|
38
|
-
return ptr;
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
let len = arg.length;
|
|
42
|
-
let ptr = malloc(len, 1) >>> 0;
|
|
43
|
-
|
|
44
|
-
const mem = getUint8ArrayMemory0();
|
|
45
|
-
|
|
46
|
-
let offset = 0;
|
|
47
|
-
|
|
48
|
-
for (; offset < len; offset++) {
|
|
49
|
-
const code = arg.charCodeAt(offset);
|
|
50
|
-
if (code > 0x7F) break;
|
|
51
|
-
mem[ptr + offset] = code;
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
if (offset !== len) {
|
|
55
|
-
if (offset !== 0) {
|
|
56
|
-
arg = arg.slice(offset);
|
|
57
|
-
}
|
|
58
|
-
ptr = realloc(ptr, len, len = offset + arg.length * 3, 1) >>> 0;
|
|
59
|
-
const view = getUint8ArrayMemory0().subarray(ptr + offset, ptr + len);
|
|
60
|
-
const ret = encodeString(arg, view);
|
|
61
|
-
|
|
62
|
-
offset += ret.written;
|
|
63
|
-
ptr = realloc(ptr, len, offset, 1) >>> 0;
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
WASM_VECTOR_LEN = offset;
|
|
67
|
-
return ptr;
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
let cachedDataViewMemory0 = null;
|
|
71
|
-
|
|
72
|
-
function getDataViewMemory0() {
|
|
73
|
-
if (cachedDataViewMemory0 === null || cachedDataViewMemory0.buffer.detached === true || (cachedDataViewMemory0.buffer.detached === undefined && cachedDataViewMemory0.buffer !== wasm.memory.buffer)) {
|
|
74
|
-
cachedDataViewMemory0 = new DataView(wasm.memory.buffer);
|
|
75
|
-
}
|
|
76
|
-
return cachedDataViewMemory0;
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
const cachedTextDecoder = (typeof TextDecoder !== 'undefined' ? new TextDecoder('utf-8', { ignoreBOM: true, fatal: true }) : { decode: () => { throw Error('TextDecoder not available') } } );
|
|
80
|
-
|
|
81
|
-
if (typeof TextDecoder !== 'undefined') { cachedTextDecoder.decode(); };
|
|
82
|
-
|
|
83
|
-
function getStringFromWasm0(ptr, len) {
|
|
84
|
-
ptr = ptr >>> 0;
|
|
85
|
-
return cachedTextDecoder.decode(getUint8ArrayMemory0().subarray(ptr, ptr + len));
|
|
86
|
-
}
|
|
87
|
-
|
|
88
|
-
function addToExternrefTable0(obj) {
|
|
89
|
-
const idx = wasm.__externref_table_alloc();
|
|
90
|
-
wasm.__wbindgen_export_5.set(idx, obj);
|
|
91
|
-
return idx;
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
function handleError(f, args) {
|
|
95
|
-
try {
|
|
96
|
-
return f.apply(this, args);
|
|
97
|
-
} catch (e) {
|
|
98
|
-
const idx = addToExternrefTable0(e);
|
|
99
|
-
wasm.__wbindgen_exn_store(idx);
|
|
100
|
-
}
|
|
101
|
-
}
|
|
102
|
-
|
|
103
|
-
function isLikeNone(x) {
|
|
104
|
-
return x === undefined || x === null;
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
const CLOSURE_DTORS = (typeof FinalizationRegistry === 'undefined')
|
|
108
|
-
? { register: () => {}, unregister: () => {} }
|
|
109
|
-
: new FinalizationRegistry(state => {
|
|
110
|
-
wasm.__wbindgen_export_6.get(state.dtor)(state.a, state.b)
|
|
111
|
-
});
|
|
112
|
-
|
|
113
|
-
function makeMutClosure(arg0, arg1, dtor, f) {
|
|
114
|
-
const state = { a: arg0, b: arg1, cnt: 1, dtor };
|
|
115
|
-
const real = (...args) => {
|
|
116
|
-
// First up with a closure we increment the internal reference
|
|
117
|
-
// count. This ensures that the Rust closure environment won't
|
|
118
|
-
// be deallocated while we're invoking it.
|
|
119
|
-
state.cnt++;
|
|
120
|
-
const a = state.a;
|
|
121
|
-
state.a = 0;
|
|
122
|
-
try {
|
|
123
|
-
return f(a, state.b, ...args);
|
|
124
|
-
} finally {
|
|
125
|
-
if (--state.cnt === 0) {
|
|
126
|
-
wasm.__wbindgen_export_6.get(state.dtor)(a, state.b);
|
|
127
|
-
CLOSURE_DTORS.unregister(state);
|
|
128
|
-
} else {
|
|
129
|
-
state.a = a;
|
|
130
|
-
}
|
|
131
|
-
}
|
|
132
|
-
};
|
|
133
|
-
real.original = state;
|
|
134
|
-
CLOSURE_DTORS.register(real, state, state);
|
|
135
|
-
return real;
|
|
136
|
-
}
|
|
137
|
-
|
|
138
|
-
function debugString(val) {
|
|
139
|
-
// primitive types
|
|
140
|
-
const type = typeof val;
|
|
141
|
-
if (type == 'number' || type == 'boolean' || val == null) {
|
|
142
|
-
return `${val}`;
|
|
143
|
-
}
|
|
144
|
-
if (type == 'string') {
|
|
145
|
-
return `"${val}"`;
|
|
146
|
-
}
|
|
147
|
-
if (type == 'symbol') {
|
|
148
|
-
const description = val.description;
|
|
149
|
-
if (description == null) {
|
|
150
|
-
return 'Symbol';
|
|
151
|
-
} else {
|
|
152
|
-
return `Symbol(${description})`;
|
|
153
|
-
}
|
|
154
|
-
}
|
|
155
|
-
if (type == 'function') {
|
|
156
|
-
const name = val.name;
|
|
157
|
-
if (typeof name == 'string' && name.length > 0) {
|
|
158
|
-
return `Function(${name})`;
|
|
159
|
-
} else {
|
|
160
|
-
return 'Function';
|
|
161
|
-
}
|
|
162
|
-
}
|
|
163
|
-
// objects
|
|
164
|
-
if (Array.isArray(val)) {
|
|
165
|
-
const length = val.length;
|
|
166
|
-
let debug = '[';
|
|
167
|
-
if (length > 0) {
|
|
168
|
-
debug += debugString(val[0]);
|
|
169
|
-
}
|
|
170
|
-
for(let i = 1; i < length; i++) {
|
|
171
|
-
debug += ', ' + debugString(val[i]);
|
|
172
|
-
}
|
|
173
|
-
debug += ']';
|
|
174
|
-
return debug;
|
|
175
|
-
}
|
|
176
|
-
// Test for built-in
|
|
177
|
-
const builtInMatches = /\[object ([^\]]+)\]/.exec(toString.call(val));
|
|
178
|
-
let className;
|
|
179
|
-
if (builtInMatches && builtInMatches.length > 1) {
|
|
180
|
-
className = builtInMatches[1];
|
|
181
|
-
} else {
|
|
182
|
-
// Failed to match the standard '[object ClassName]'
|
|
183
|
-
return toString.call(val);
|
|
184
|
-
}
|
|
185
|
-
if (className == 'Object') {
|
|
186
|
-
// we're a user defined class or Object
|
|
187
|
-
// JSON.stringify avoids problems with cycles, and is generally much
|
|
188
|
-
// easier than looping through ownProperties of `val`.
|
|
189
|
-
try {
|
|
190
|
-
return 'Object(' + JSON.stringify(val) + ')';
|
|
191
|
-
} catch (_) {
|
|
192
|
-
return 'Object';
|
|
193
|
-
}
|
|
194
|
-
}
|
|
195
|
-
// errors
|
|
196
|
-
if (val instanceof Error) {
|
|
197
|
-
return `${val.name}: ${val.message}\n${val.stack}`;
|
|
198
|
-
}
|
|
199
|
-
// TODO we could test for more things here, like `Set`s and `Map`s.
|
|
200
|
-
return className;
|
|
201
|
-
}
|
|
202
|
-
|
|
203
|
-
function getArrayJsValueFromWasm0(ptr, len) {
|
|
204
|
-
ptr = ptr >>> 0;
|
|
205
|
-
const mem = getDataViewMemory0();
|
|
206
|
-
const result = [];
|
|
207
|
-
for (let i = ptr; i < ptr + 4 * len; i += 4) {
|
|
208
|
-
result.push(wasm.__wbindgen_export_5.get(mem.getUint32(i, true)));
|
|
209
|
-
}
|
|
210
|
-
wasm.__externref_drop_slice(ptr, len);
|
|
211
|
-
return result;
|
|
212
|
-
}
|
|
213
|
-
|
|
214
|
-
function passArrayJsValueToWasm0(array, malloc) {
|
|
215
|
-
const ptr = malloc(array.length * 4, 4) >>> 0;
|
|
216
|
-
for (let i = 0; i < array.length; i++) {
|
|
217
|
-
const add = addToExternrefTable0(array[i]);
|
|
218
|
-
getDataViewMemory0().setUint32(ptr + 4 * i, add, true);
|
|
219
|
-
}
|
|
220
|
-
WASM_VECTOR_LEN = array.length;
|
|
221
|
-
return ptr;
|
|
222
|
-
}
|
|
223
|
-
|
|
224
|
-
function _assertClass(instance, klass) {
|
|
225
|
-
if (!(instance instanceof klass)) {
|
|
226
|
-
throw new Error(`expected instance of ${klass.name}`);
|
|
227
|
-
}
|
|
228
|
-
}
|
|
229
|
-
|
|
230
|
-
function getArrayU8FromWasm0(ptr, len) {
|
|
231
|
-
ptr = ptr >>> 0;
|
|
232
|
-
return getUint8ArrayMemory0().subarray(ptr / 1, ptr / 1 + len);
|
|
233
|
-
}
|
|
234
|
-
|
|
235
|
-
function passArray8ToWasm0(arg, malloc) {
|
|
236
|
-
const ptr = malloc(arg.length * 1, 1) >>> 0;
|
|
237
|
-
getUint8ArrayMemory0().set(arg, ptr / 1);
|
|
238
|
-
WASM_VECTOR_LEN = arg.length;
|
|
239
|
-
return ptr;
|
|
240
|
-
}
|
|
241
|
-
|
|
242
|
-
function takeFromExternrefTable0(idx) {
|
|
243
|
-
const value = wasm.__wbindgen_export_5.get(idx);
|
|
244
|
-
wasm.__externref_table_dealloc(idx);
|
|
245
|
-
return value;
|
|
246
|
-
}
|
|
247
|
-
/**
|
|
248
|
-
* @param {string} host
|
|
249
|
-
* @param {string} account_address
|
|
250
|
-
* @returns {Promise<string | undefined>}
|
|
251
|
-
*/
|
|
252
|
-
export function getInboxIdForAddress(host, account_address) {
|
|
253
|
-
const ptr0 = passStringToWasm0(host, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
254
|
-
const len0 = WASM_VECTOR_LEN;
|
|
255
|
-
const ptr1 = passStringToWasm0(account_address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
256
|
-
const len1 = WASM_VECTOR_LEN;
|
|
257
|
-
const ret = wasm.getInboxIdForAddress(ptr0, len0, ptr1, len1);
|
|
258
|
-
return ret;
|
|
259
|
-
}
|
|
260
|
-
|
|
261
|
-
/**
|
|
262
|
-
* @param {string} account_address
|
|
263
|
-
* @returns {string}
|
|
264
|
-
*/
|
|
265
|
-
export function generateInboxId(account_address) {
|
|
266
|
-
let deferred3_0;
|
|
267
|
-
let deferred3_1;
|
|
268
|
-
try {
|
|
269
|
-
const ptr0 = passStringToWasm0(account_address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
270
|
-
const len0 = WASM_VECTOR_LEN;
|
|
271
|
-
const ret = wasm.generateInboxId(ptr0, len0);
|
|
272
|
-
var ptr2 = ret[0];
|
|
273
|
-
var len2 = ret[1];
|
|
274
|
-
if (ret[3]) {
|
|
275
|
-
ptr2 = 0; len2 = 0;
|
|
276
|
-
throw takeFromExternrefTable0(ret[2]);
|
|
277
|
-
}
|
|
278
|
-
deferred3_0 = ptr2;
|
|
279
|
-
deferred3_1 = len2;
|
|
280
|
-
return getStringFromWasm0(ptr2, len2);
|
|
281
|
-
} finally {
|
|
282
|
-
wasm.__wbindgen_free(deferred3_0, deferred3_1, 1);
|
|
283
|
-
}
|
|
284
|
-
}
|
|
285
|
-
|
|
286
|
-
/**
|
|
287
|
-
* @param {string} signature_text
|
|
288
|
-
* @param {Uint8Array} signature_bytes
|
|
289
|
-
* @param {Uint8Array} public_key
|
|
290
|
-
*/
|
|
291
|
-
export function verifySignedWithPublicKey(signature_text, signature_bytes, public_key) {
|
|
292
|
-
const ptr0 = passStringToWasm0(signature_text, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
293
|
-
const len0 = WASM_VECTOR_LEN;
|
|
294
|
-
const ret = wasm.verifySignedWithPublicKey(ptr0, len0, signature_bytes, public_key);
|
|
295
|
-
if (ret[1]) {
|
|
296
|
-
throw takeFromExternrefTable0(ret[0]);
|
|
297
|
-
}
|
|
298
|
-
}
|
|
299
|
-
|
|
300
|
-
/**
|
|
301
|
-
* @param {string} host
|
|
302
|
-
* @param {string} inbox_id
|
|
303
|
-
* @param {string} account_address
|
|
304
|
-
* @param {string | null} [db_path]
|
|
305
|
-
* @param {Uint8Array | null} [encryption_key]
|
|
306
|
-
* @param {string | null} [history_sync_url]
|
|
307
|
-
* @param {LogOptions | null} [log_options]
|
|
308
|
-
* @returns {Promise<Client>}
|
|
309
|
-
*/
|
|
310
|
-
export function createClient(host, inbox_id, account_address, db_path, encryption_key, history_sync_url, log_options) {
|
|
311
|
-
const ptr0 = passStringToWasm0(host, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
312
|
-
const len0 = WASM_VECTOR_LEN;
|
|
313
|
-
const ptr1 = passStringToWasm0(inbox_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
314
|
-
const len1 = WASM_VECTOR_LEN;
|
|
315
|
-
const ptr2 = passStringToWasm0(account_address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
316
|
-
const len2 = WASM_VECTOR_LEN;
|
|
317
|
-
var ptr3 = isLikeNone(db_path) ? 0 : passStringToWasm0(db_path, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
318
|
-
var len3 = WASM_VECTOR_LEN;
|
|
319
|
-
var ptr4 = isLikeNone(history_sync_url) ? 0 : passStringToWasm0(history_sync_url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
320
|
-
var len4 = WASM_VECTOR_LEN;
|
|
321
|
-
let ptr5 = 0;
|
|
322
|
-
if (!isLikeNone(log_options)) {
|
|
323
|
-
_assertClass(log_options, LogOptions);
|
|
324
|
-
ptr5 = log_options.__destroy_into_raw();
|
|
325
|
-
}
|
|
326
|
-
const ret = wasm.createClient(ptr0, len0, ptr1, len1, ptr2, len2, ptr3, len3, isLikeNone(encryption_key) ? 0 : addToExternrefTable0(encryption_key), ptr4, len4, ptr5);
|
|
327
|
-
return ret;
|
|
328
|
-
}
|
|
329
|
-
|
|
330
|
-
function __wbg_adapter_52(arg0, arg1) {
|
|
331
|
-
wasm._dyn_core__ops__function__FnMut_____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__hb21f8cddfb9e179d(arg0, arg1);
|
|
332
|
-
}
|
|
333
|
-
|
|
334
|
-
function __wbg_adapter_55(arg0, arg1, arg2) {
|
|
335
|
-
wasm.closure2971_externref_shim(arg0, arg1, arg2);
|
|
336
|
-
}
|
|
337
|
-
|
|
338
|
-
function __wbg_adapter_646(arg0, arg1, arg2, arg3) {
|
|
339
|
-
wasm.closure3993_externref_shim(arg0, arg1, arg2, arg3);
|
|
340
|
-
}
|
|
341
|
-
|
|
342
|
-
/**
|
|
343
|
-
* @enum {0 | 1 | 2}
|
|
344
|
-
*/
|
|
345
|
-
export const ConsentEntityType = Object.freeze({
|
|
346
|
-
GroupId: 0, "0": "GroupId",
|
|
347
|
-
InboxId: 1, "1": "InboxId",
|
|
348
|
-
Address: 2, "2": "Address",
|
|
349
|
-
});
|
|
350
|
-
/**
|
|
351
|
-
* @enum {0 | 1 | 2}
|
|
352
|
-
*/
|
|
353
|
-
export const ConsentState = Object.freeze({
|
|
354
|
-
Unknown: 0, "0": "Unknown",
|
|
355
|
-
Allowed: 1, "1": "Allowed",
|
|
356
|
-
Denied: 2, "2": "Denied",
|
|
357
|
-
});
|
|
358
|
-
/**
|
|
359
|
-
* @enum {0 | 1 | 2}
|
|
360
|
-
*/
|
|
361
|
-
export const ConversationType = Object.freeze({
|
|
362
|
-
Dm: 0, "0": "Dm",
|
|
363
|
-
Group: 1, "1": "Group",
|
|
364
|
-
Sync: 2, "2": "Sync",
|
|
365
|
-
});
|
|
366
|
-
/**
|
|
367
|
-
* @enum {0 | 1 | 2}
|
|
368
|
-
*/
|
|
369
|
-
export const DeliveryStatus = Object.freeze({
|
|
370
|
-
Unpublished: 0, "0": "Unpublished",
|
|
371
|
-
Published: 1, "1": "Published",
|
|
372
|
-
Failed: 2, "2": "Failed",
|
|
373
|
-
});
|
|
374
|
-
/**
|
|
375
|
-
* @enum {0 | 1 | 2}
|
|
376
|
-
*/
|
|
377
|
-
export const GroupMembershipState = Object.freeze({
|
|
378
|
-
Allowed: 0, "0": "Allowed",
|
|
379
|
-
Rejected: 1, "1": "Rejected",
|
|
380
|
-
Pending: 2, "2": "Pending",
|
|
381
|
-
});
|
|
382
|
-
/**
|
|
383
|
-
* @enum {0 | 1}
|
|
384
|
-
*/
|
|
385
|
-
export const GroupMessageKind = Object.freeze({
|
|
386
|
-
Application: 0, "0": "Application",
|
|
387
|
-
MembershipChange: 1, "1": "MembershipChange",
|
|
388
|
-
});
|
|
389
|
-
/**
|
|
390
|
-
* @enum {0 | 1 | 2}
|
|
391
|
-
*/
|
|
392
|
-
export const GroupPermissionsOptions = Object.freeze({
|
|
393
|
-
Default: 0, "0": "Default",
|
|
394
|
-
AdminOnly: 1, "1": "AdminOnly",
|
|
395
|
-
CustomPolicy: 2, "2": "CustomPolicy",
|
|
396
|
-
});
|
|
397
|
-
/**
|
|
398
|
-
* @enum {0 | 1 | 2 | 3 | 4}
|
|
399
|
-
*/
|
|
400
|
-
export const MetadataField = Object.freeze({
|
|
401
|
-
GroupName: 0, "0": "GroupName",
|
|
402
|
-
Description: 1, "1": "Description",
|
|
403
|
-
ImageUrlSquare: 2, "2": "ImageUrlSquare",
|
|
404
|
-
MessageExpirationFromMS: 3, "3": "MessageExpirationFromMS",
|
|
405
|
-
MessageExpirationMS: 4, "4": "MessageExpirationMS",
|
|
406
|
-
});
|
|
407
|
-
/**
|
|
408
|
-
* @enum {0 | 1 | 2}
|
|
409
|
-
*/
|
|
410
|
-
export const PermissionLevel = Object.freeze({
|
|
411
|
-
Member: 0, "0": "Member",
|
|
412
|
-
Admin: 1, "1": "Admin",
|
|
413
|
-
SuperAdmin: 2, "2": "SuperAdmin",
|
|
414
|
-
});
|
|
415
|
-
/**
|
|
416
|
-
* @enum {0 | 1 | 2 | 3 | 4 | 5}
|
|
417
|
-
*/
|
|
418
|
-
export const PermissionPolicy = Object.freeze({
|
|
419
|
-
Allow: 0, "0": "Allow",
|
|
420
|
-
Deny: 1, "1": "Deny",
|
|
421
|
-
Admin: 2, "2": "Admin",
|
|
422
|
-
SuperAdmin: 3, "3": "SuperAdmin",
|
|
423
|
-
DoesNotExist: 4, "4": "DoesNotExist",
|
|
424
|
-
Other: 5, "5": "Other",
|
|
425
|
-
});
|
|
426
|
-
/**
|
|
427
|
-
* @enum {0 | 1 | 2 | 3 | 4}
|
|
428
|
-
*/
|
|
429
|
-
export const PermissionUpdateType = Object.freeze({
|
|
430
|
-
AddMember: 0, "0": "AddMember",
|
|
431
|
-
RemoveMember: 1, "1": "RemoveMember",
|
|
432
|
-
AddAdmin: 2, "2": "AddAdmin",
|
|
433
|
-
RemoveAdmin: 3, "3": "RemoveAdmin",
|
|
434
|
-
UpdateMetadata: 4, "4": "UpdateMetadata",
|
|
435
|
-
});
|
|
436
|
-
/**
|
|
437
|
-
* @enum {0 | 1 | 2 | 3}
|
|
438
|
-
*/
|
|
439
|
-
export const SignatureRequestType = Object.freeze({
|
|
440
|
-
AddWallet: 0, "0": "AddWallet",
|
|
441
|
-
CreateInbox: 1, "1": "CreateInbox",
|
|
442
|
-
RevokeWallet: 2, "2": "RevokeWallet",
|
|
443
|
-
RevokeInstallations: 3, "3": "RevokeInstallations",
|
|
444
|
-
});
|
|
445
|
-
/**
|
|
446
|
-
* @enum {0 | 1}
|
|
447
|
-
*/
|
|
448
|
-
export const SortDirection = Object.freeze({
|
|
449
|
-
Ascending: 0, "0": "Ascending",
|
|
450
|
-
Descending: 1, "1": "Descending",
|
|
451
|
-
});
|
|
452
|
-
|
|
453
|
-
const __wbindgen_enum_LogLevel = ["off", "error", "warn", "info", "debug", "trace"];
|
|
454
|
-
|
|
455
|
-
const __wbindgen_enum_ReadableStreamType = ["bytes"];
|
|
456
|
-
|
|
457
|
-
const __wbindgen_enum_RequestCredentials = ["omit", "same-origin", "include"];
|
|
458
|
-
|
|
459
|
-
const __wbindgen_enum_RequestMode = ["same-origin", "no-cors", "cors", "navigate"];
|
|
460
|
-
|
|
461
|
-
const ClientFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
462
|
-
? { register: () => {}, unregister: () => {} }
|
|
463
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_client_free(ptr >>> 0, 1));
|
|
464
|
-
|
|
465
|
-
export class Client {
|
|
466
|
-
|
|
467
|
-
static __wrap(ptr) {
|
|
468
|
-
ptr = ptr >>> 0;
|
|
469
|
-
const obj = Object.create(Client.prototype);
|
|
470
|
-
obj.__wbg_ptr = ptr;
|
|
471
|
-
ClientFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
472
|
-
return obj;
|
|
473
|
-
}
|
|
474
|
-
|
|
475
|
-
__destroy_into_raw() {
|
|
476
|
-
const ptr = this.__wbg_ptr;
|
|
477
|
-
this.__wbg_ptr = 0;
|
|
478
|
-
ClientFinalization.unregister(this);
|
|
479
|
-
return ptr;
|
|
480
|
-
}
|
|
481
|
-
|
|
482
|
-
free() {
|
|
483
|
-
const ptr = this.__destroy_into_raw();
|
|
484
|
-
wasm.__wbg_client_free(ptr, 0);
|
|
485
|
-
}
|
|
486
|
-
/**
|
|
487
|
-
* @returns {string | undefined}
|
|
488
|
-
*/
|
|
489
|
-
createInboxSignatureText() {
|
|
490
|
-
const ret = wasm.client_createInboxSignatureText(this.__wbg_ptr);
|
|
491
|
-
if (ret[3]) {
|
|
492
|
-
throw takeFromExternrefTable0(ret[2]);
|
|
493
|
-
}
|
|
494
|
-
let v1;
|
|
495
|
-
if (ret[0] !== 0) {
|
|
496
|
-
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
497
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
498
|
-
}
|
|
499
|
-
return v1;
|
|
500
|
-
}
|
|
501
|
-
/**
|
|
502
|
-
* @param {string} new_wallet_address
|
|
503
|
-
* @returns {Promise<string>}
|
|
504
|
-
*/
|
|
505
|
-
addWalletSignatureText(new_wallet_address) {
|
|
506
|
-
const ptr0 = passStringToWasm0(new_wallet_address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
507
|
-
const len0 = WASM_VECTOR_LEN;
|
|
508
|
-
const ret = wasm.client_addWalletSignatureText(this.__wbg_ptr, ptr0, len0);
|
|
509
|
-
return ret;
|
|
510
|
-
}
|
|
511
|
-
/**
|
|
512
|
-
* @param {string} wallet_address
|
|
513
|
-
* @returns {Promise<string>}
|
|
514
|
-
*/
|
|
515
|
-
revokeWalletSignatureText(wallet_address) {
|
|
516
|
-
const ptr0 = passStringToWasm0(wallet_address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
517
|
-
const len0 = WASM_VECTOR_LEN;
|
|
518
|
-
const ret = wasm.client_revokeWalletSignatureText(this.__wbg_ptr, ptr0, len0);
|
|
519
|
-
return ret;
|
|
520
|
-
}
|
|
521
|
-
/**
|
|
522
|
-
* @returns {Promise<string>}
|
|
523
|
-
*/
|
|
524
|
-
revokeAllOtherInstallationsSignatureText() {
|
|
525
|
-
const ret = wasm.client_revokeAllOtherInstallationsSignatureText(this.__wbg_ptr);
|
|
526
|
-
return ret;
|
|
527
|
-
}
|
|
528
|
-
/**
|
|
529
|
-
* @param {Uint8Array[]} installation_ids
|
|
530
|
-
* @returns {Promise<string>}
|
|
531
|
-
*/
|
|
532
|
-
revokeInstallationsSignatureText(installation_ids) {
|
|
533
|
-
const ptr0 = passArrayJsValueToWasm0(installation_ids, wasm.__wbindgen_malloc);
|
|
534
|
-
const len0 = WASM_VECTOR_LEN;
|
|
535
|
-
const ret = wasm.client_revokeInstallationsSignatureText(this.__wbg_ptr, ptr0, len0);
|
|
536
|
-
return ret;
|
|
537
|
-
}
|
|
538
|
-
/**
|
|
539
|
-
* @param {SignatureRequestType} signature_type
|
|
540
|
-
* @param {Uint8Array} signature_bytes
|
|
541
|
-
* @returns {Promise<void>}
|
|
542
|
-
*/
|
|
543
|
-
addSignature(signature_type, signature_bytes) {
|
|
544
|
-
const ret = wasm.client_addSignature(this.__wbg_ptr, signature_type, signature_bytes);
|
|
545
|
-
return ret;
|
|
546
|
-
}
|
|
547
|
-
/**
|
|
548
|
-
* @param {SignatureRequestType} signature_type
|
|
549
|
-
* @param {Uint8Array} signature_bytes
|
|
550
|
-
* @param {bigint} chain_id
|
|
551
|
-
* @param {bigint | null} [block_number]
|
|
552
|
-
* @returns {Promise<void>}
|
|
553
|
-
*/
|
|
554
|
-
addScwSignature(signature_type, signature_bytes, chain_id, block_number) {
|
|
555
|
-
const ret = wasm.client_addScwSignature(this.__wbg_ptr, signature_type, signature_bytes, chain_id, !isLikeNone(block_number), isLikeNone(block_number) ? BigInt(0) : block_number);
|
|
556
|
-
return ret;
|
|
557
|
-
}
|
|
558
|
-
/**
|
|
559
|
-
* @returns {Promise<void>}
|
|
560
|
-
*/
|
|
561
|
-
applySignatureRequests() {
|
|
562
|
-
const ret = wasm.client_applySignatureRequests(this.__wbg_ptr);
|
|
563
|
-
return ret;
|
|
564
|
-
}
|
|
565
|
-
/**
|
|
566
|
-
* @param {string} signature_text
|
|
567
|
-
* @returns {Uint8Array}
|
|
568
|
-
*/
|
|
569
|
-
signWithInstallationKey(signature_text) {
|
|
570
|
-
const ptr0 = passStringToWasm0(signature_text, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
571
|
-
const len0 = WASM_VECTOR_LEN;
|
|
572
|
-
const ret = wasm.client_signWithInstallationKey(this.__wbg_ptr, ptr0, len0);
|
|
573
|
-
if (ret[2]) {
|
|
574
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
575
|
-
}
|
|
576
|
-
return takeFromExternrefTable0(ret[0]);
|
|
577
|
-
}
|
|
578
|
-
/**
|
|
579
|
-
* @param {string} signature_text
|
|
580
|
-
* @param {Uint8Array} signature_bytes
|
|
581
|
-
*/
|
|
582
|
-
verifySignedWithInstallationKey(signature_text, signature_bytes) {
|
|
583
|
-
const ptr0 = passStringToWasm0(signature_text, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
584
|
-
const len0 = WASM_VECTOR_LEN;
|
|
585
|
-
const ret = wasm.client_verifySignedWithInstallationKey(this.__wbg_ptr, ptr0, len0, signature_bytes);
|
|
586
|
-
if (ret[1]) {
|
|
587
|
-
throw takeFromExternrefTable0(ret[0]);
|
|
588
|
-
}
|
|
589
|
-
}
|
|
590
|
-
/**
|
|
591
|
-
* @returns {string}
|
|
592
|
-
*/
|
|
593
|
-
get accountAddress() {
|
|
594
|
-
let deferred1_0;
|
|
595
|
-
let deferred1_1;
|
|
596
|
-
try {
|
|
597
|
-
const ret = wasm.client_accountAddress(this.__wbg_ptr);
|
|
598
|
-
deferred1_0 = ret[0];
|
|
599
|
-
deferred1_1 = ret[1];
|
|
600
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
601
|
-
} finally {
|
|
602
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
603
|
-
}
|
|
604
|
-
}
|
|
605
|
-
/**
|
|
606
|
-
* @returns {string}
|
|
607
|
-
*/
|
|
608
|
-
get inboxId() {
|
|
609
|
-
let deferred1_0;
|
|
610
|
-
let deferred1_1;
|
|
611
|
-
try {
|
|
612
|
-
const ret = wasm.client_inboxId(this.__wbg_ptr);
|
|
613
|
-
deferred1_0 = ret[0];
|
|
614
|
-
deferred1_1 = ret[1];
|
|
615
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
616
|
-
} finally {
|
|
617
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
618
|
-
}
|
|
619
|
-
}
|
|
620
|
-
/**
|
|
621
|
-
* @returns {boolean}
|
|
622
|
-
*/
|
|
623
|
-
get isRegistered() {
|
|
624
|
-
const ret = wasm.client_isRegistered(this.__wbg_ptr);
|
|
625
|
-
return ret !== 0;
|
|
626
|
-
}
|
|
627
|
-
/**
|
|
628
|
-
* @returns {string}
|
|
629
|
-
*/
|
|
630
|
-
get installationId() {
|
|
631
|
-
let deferred1_0;
|
|
632
|
-
let deferred1_1;
|
|
633
|
-
try {
|
|
634
|
-
const ret = wasm.client_installationId(this.__wbg_ptr);
|
|
635
|
-
deferred1_0 = ret[0];
|
|
636
|
-
deferred1_1 = ret[1];
|
|
637
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
638
|
-
} finally {
|
|
639
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
640
|
-
}
|
|
641
|
-
}
|
|
642
|
-
/**
|
|
643
|
-
* @returns {Uint8Array}
|
|
644
|
-
*/
|
|
645
|
-
get installationIdBytes() {
|
|
646
|
-
const ret = wasm.client_installationIdBytes(this.__wbg_ptr);
|
|
647
|
-
return ret;
|
|
648
|
-
}
|
|
649
|
-
/**
|
|
650
|
-
* @param {string[]} account_addresses
|
|
651
|
-
* @returns {Promise<any>}
|
|
652
|
-
*/
|
|
653
|
-
canMessage(account_addresses) {
|
|
654
|
-
const ptr0 = passArrayJsValueToWasm0(account_addresses, wasm.__wbindgen_malloc);
|
|
655
|
-
const len0 = WASM_VECTOR_LEN;
|
|
656
|
-
const ret = wasm.client_canMessage(this.__wbg_ptr, ptr0, len0);
|
|
657
|
-
return ret;
|
|
658
|
-
}
|
|
659
|
-
/**
|
|
660
|
-
* @returns {Promise<void>}
|
|
661
|
-
*/
|
|
662
|
-
registerIdentity() {
|
|
663
|
-
const ret = wasm.client_registerIdentity(this.__wbg_ptr);
|
|
664
|
-
return ret;
|
|
665
|
-
}
|
|
666
|
-
/**
|
|
667
|
-
* @returns {Promise<void>}
|
|
668
|
-
*/
|
|
669
|
-
sendHistorySyncRequest() {
|
|
670
|
-
const ret = wasm.client_sendHistorySyncRequest(this.__wbg_ptr);
|
|
671
|
-
return ret;
|
|
672
|
-
}
|
|
673
|
-
/**
|
|
674
|
-
* @returns {Promise<void>}
|
|
675
|
-
*/
|
|
676
|
-
sendConsentSyncRequest() {
|
|
677
|
-
const ret = wasm.client_sendConsentSyncRequest(this.__wbg_ptr);
|
|
678
|
-
return ret;
|
|
679
|
-
}
|
|
680
|
-
/**
|
|
681
|
-
* @param {string} address
|
|
682
|
-
* @returns {Promise<string | undefined>}
|
|
683
|
-
*/
|
|
684
|
-
findInboxIdByAddress(address) {
|
|
685
|
-
const ptr0 = passStringToWasm0(address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
686
|
-
const len0 = WASM_VECTOR_LEN;
|
|
687
|
-
const ret = wasm.client_findInboxIdByAddress(this.__wbg_ptr, ptr0, len0);
|
|
688
|
-
return ret;
|
|
689
|
-
}
|
|
690
|
-
/**
|
|
691
|
-
* @returns {Conversations}
|
|
692
|
-
*/
|
|
693
|
-
conversations() {
|
|
694
|
-
const ret = wasm.client_conversations(this.__wbg_ptr);
|
|
695
|
-
return Conversations.__wrap(ret);
|
|
696
|
-
}
|
|
697
|
-
/**
|
|
698
|
-
* @param {Consent[]} records
|
|
699
|
-
* @returns {Promise<void>}
|
|
700
|
-
*/
|
|
701
|
-
setConsentStates(records) {
|
|
702
|
-
const ptr0 = passArrayJsValueToWasm0(records, wasm.__wbindgen_malloc);
|
|
703
|
-
const len0 = WASM_VECTOR_LEN;
|
|
704
|
-
const ret = wasm.client_setConsentStates(this.__wbg_ptr, ptr0, len0);
|
|
705
|
-
return ret;
|
|
706
|
-
}
|
|
707
|
-
/**
|
|
708
|
-
* @param {ConsentEntityType} entity_type
|
|
709
|
-
* @param {string} entity
|
|
710
|
-
* @returns {Promise<ConsentState>}
|
|
711
|
-
*/
|
|
712
|
-
getConsentState(entity_type, entity) {
|
|
713
|
-
const ptr0 = passStringToWasm0(entity, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
714
|
-
const len0 = WASM_VECTOR_LEN;
|
|
715
|
-
const ret = wasm.client_getConsentState(this.__wbg_ptr, entity_type, ptr0, len0);
|
|
716
|
-
return ret;
|
|
717
|
-
}
|
|
718
|
-
/**
|
|
719
|
-
*
|
|
720
|
-
* * Get the client's inbox state.
|
|
721
|
-
* *
|
|
722
|
-
* * If `refresh_from_network` is true, the client will go to the network first to refresh the state.
|
|
723
|
-
* * Otherwise, the state will be read from the local database.
|
|
724
|
-
*
|
|
725
|
-
* @param {boolean} refresh_from_network
|
|
726
|
-
* @returns {Promise<InboxState>}
|
|
727
|
-
*/
|
|
728
|
-
inboxState(refresh_from_network) {
|
|
729
|
-
const ret = wasm.client_inboxState(this.__wbg_ptr, refresh_from_network);
|
|
730
|
-
return ret;
|
|
731
|
-
}
|
|
732
|
-
/**
|
|
733
|
-
* @param {string} inbox_id
|
|
734
|
-
* @returns {Promise<InboxState>}
|
|
735
|
-
*/
|
|
736
|
-
getLatestInboxState(inbox_id) {
|
|
737
|
-
const ptr0 = passStringToWasm0(inbox_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
738
|
-
const len0 = WASM_VECTOR_LEN;
|
|
739
|
-
const ret = wasm.client_getLatestInboxState(this.__wbg_ptr, ptr0, len0);
|
|
740
|
-
return ret;
|
|
741
|
-
}
|
|
742
|
-
}
|
|
743
|
-
|
|
744
|
-
const ConsentFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
745
|
-
? { register: () => {}, unregister: () => {} }
|
|
746
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_consent_free(ptr >>> 0, 1));
|
|
747
|
-
|
|
748
|
-
export class Consent {
|
|
749
|
-
|
|
750
|
-
static __unwrap(jsValue) {
|
|
751
|
-
if (!(jsValue instanceof Consent)) {
|
|
752
|
-
return 0;
|
|
753
|
-
}
|
|
754
|
-
return jsValue.__destroy_into_raw();
|
|
755
|
-
}
|
|
756
|
-
|
|
757
|
-
__destroy_into_raw() {
|
|
758
|
-
const ptr = this.__wbg_ptr;
|
|
759
|
-
this.__wbg_ptr = 0;
|
|
760
|
-
ConsentFinalization.unregister(this);
|
|
761
|
-
return ptr;
|
|
762
|
-
}
|
|
763
|
-
|
|
764
|
-
free() {
|
|
765
|
-
const ptr = this.__destroy_into_raw();
|
|
766
|
-
wasm.__wbg_consent_free(ptr, 0);
|
|
767
|
-
}
|
|
768
|
-
/**
|
|
769
|
-
* @returns {ConsentEntityType}
|
|
770
|
-
*/
|
|
771
|
-
get entityType() {
|
|
772
|
-
const ret = wasm.__wbg_get_consent_entityType(this.__wbg_ptr);
|
|
773
|
-
return ret;
|
|
774
|
-
}
|
|
775
|
-
/**
|
|
776
|
-
* @param {ConsentEntityType} arg0
|
|
777
|
-
*/
|
|
778
|
-
set entityType(arg0) {
|
|
779
|
-
wasm.__wbg_set_consent_entityType(this.__wbg_ptr, arg0);
|
|
780
|
-
}
|
|
781
|
-
/**
|
|
782
|
-
* @returns {ConsentState}
|
|
783
|
-
*/
|
|
784
|
-
get state() {
|
|
785
|
-
const ret = wasm.__wbg_get_consent_state(this.__wbg_ptr);
|
|
786
|
-
return ret;
|
|
787
|
-
}
|
|
788
|
-
/**
|
|
789
|
-
* @param {ConsentState} arg0
|
|
790
|
-
*/
|
|
791
|
-
set state(arg0) {
|
|
792
|
-
wasm.__wbg_set_consent_state(this.__wbg_ptr, arg0);
|
|
793
|
-
}
|
|
794
|
-
/**
|
|
795
|
-
* @returns {string}
|
|
796
|
-
*/
|
|
797
|
-
get entity() {
|
|
798
|
-
let deferred1_0;
|
|
799
|
-
let deferred1_1;
|
|
800
|
-
try {
|
|
801
|
-
const ret = wasm.__wbg_get_consent_entity(this.__wbg_ptr);
|
|
802
|
-
deferred1_0 = ret[0];
|
|
803
|
-
deferred1_1 = ret[1];
|
|
804
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
805
|
-
} finally {
|
|
806
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
807
|
-
}
|
|
808
|
-
}
|
|
809
|
-
/**
|
|
810
|
-
* @param {string} arg0
|
|
811
|
-
*/
|
|
812
|
-
set entity(arg0) {
|
|
813
|
-
const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
814
|
-
const len0 = WASM_VECTOR_LEN;
|
|
815
|
-
wasm.__wbg_set_consent_entity(this.__wbg_ptr, ptr0, len0);
|
|
816
|
-
}
|
|
817
|
-
/**
|
|
818
|
-
* @param {ConsentEntityType} entity_type
|
|
819
|
-
* @param {ConsentState} state
|
|
820
|
-
* @param {string} entity
|
|
821
|
-
*/
|
|
822
|
-
constructor(entity_type, state, entity) {
|
|
823
|
-
const ptr0 = passStringToWasm0(entity, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
824
|
-
const len0 = WASM_VECTOR_LEN;
|
|
825
|
-
const ret = wasm.consent_new(entity_type, state, ptr0, len0);
|
|
826
|
-
this.__wbg_ptr = ret >>> 0;
|
|
827
|
-
ConsentFinalization.register(this, this.__wbg_ptr, this);
|
|
828
|
-
return this;
|
|
829
|
-
}
|
|
830
|
-
}
|
|
831
|
-
|
|
832
|
-
const ContentTypeIdFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
833
|
-
? { register: () => {}, unregister: () => {} }
|
|
834
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_contenttypeid_free(ptr >>> 0, 1));
|
|
835
|
-
|
|
836
|
-
export class ContentTypeId {
|
|
837
|
-
|
|
838
|
-
static __wrap(ptr) {
|
|
839
|
-
ptr = ptr >>> 0;
|
|
840
|
-
const obj = Object.create(ContentTypeId.prototype);
|
|
841
|
-
obj.__wbg_ptr = ptr;
|
|
842
|
-
ContentTypeIdFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
843
|
-
return obj;
|
|
844
|
-
}
|
|
845
|
-
|
|
846
|
-
__destroy_into_raw() {
|
|
847
|
-
const ptr = this.__wbg_ptr;
|
|
848
|
-
this.__wbg_ptr = 0;
|
|
849
|
-
ContentTypeIdFinalization.unregister(this);
|
|
850
|
-
return ptr;
|
|
851
|
-
}
|
|
852
|
-
|
|
853
|
-
free() {
|
|
854
|
-
const ptr = this.__destroy_into_raw();
|
|
855
|
-
wasm.__wbg_contenttypeid_free(ptr, 0);
|
|
856
|
-
}
|
|
857
|
-
/**
|
|
858
|
-
* @returns {string}
|
|
859
|
-
*/
|
|
860
|
-
get authorityId() {
|
|
861
|
-
let deferred1_0;
|
|
862
|
-
let deferred1_1;
|
|
863
|
-
try {
|
|
864
|
-
const ret = wasm.__wbg_get_contenttypeid_authorityId(this.__wbg_ptr);
|
|
865
|
-
deferred1_0 = ret[0];
|
|
866
|
-
deferred1_1 = ret[1];
|
|
867
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
868
|
-
} finally {
|
|
869
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
870
|
-
}
|
|
871
|
-
}
|
|
872
|
-
/**
|
|
873
|
-
* @param {string} arg0
|
|
874
|
-
*/
|
|
875
|
-
set authorityId(arg0) {
|
|
876
|
-
const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
877
|
-
const len0 = WASM_VECTOR_LEN;
|
|
878
|
-
wasm.__wbg_set_consent_entity(this.__wbg_ptr, ptr0, len0);
|
|
879
|
-
}
|
|
880
|
-
/**
|
|
881
|
-
* @returns {string}
|
|
882
|
-
*/
|
|
883
|
-
get typeId() {
|
|
884
|
-
let deferred1_0;
|
|
885
|
-
let deferred1_1;
|
|
886
|
-
try {
|
|
887
|
-
const ret = wasm.__wbg_get_contenttypeid_typeId(this.__wbg_ptr);
|
|
888
|
-
deferred1_0 = ret[0];
|
|
889
|
-
deferred1_1 = ret[1];
|
|
890
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
891
|
-
} finally {
|
|
892
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
893
|
-
}
|
|
894
|
-
}
|
|
895
|
-
/**
|
|
896
|
-
* @param {string} arg0
|
|
897
|
-
*/
|
|
898
|
-
set typeId(arg0) {
|
|
899
|
-
const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
900
|
-
const len0 = WASM_VECTOR_LEN;
|
|
901
|
-
wasm.__wbg_set_contenttypeid_typeId(this.__wbg_ptr, ptr0, len0);
|
|
902
|
-
}
|
|
903
|
-
/**
|
|
904
|
-
* @returns {number}
|
|
905
|
-
*/
|
|
906
|
-
get versionMajor() {
|
|
907
|
-
const ret = wasm.__wbg_get_contenttypeid_versionMajor(this.__wbg_ptr);
|
|
908
|
-
return ret >>> 0;
|
|
909
|
-
}
|
|
910
|
-
/**
|
|
911
|
-
* @param {number} arg0
|
|
912
|
-
*/
|
|
913
|
-
set versionMajor(arg0) {
|
|
914
|
-
wasm.__wbg_set_contenttypeid_versionMajor(this.__wbg_ptr, arg0);
|
|
915
|
-
}
|
|
916
|
-
/**
|
|
917
|
-
* @returns {number}
|
|
918
|
-
*/
|
|
919
|
-
get versionMinor() {
|
|
920
|
-
const ret = wasm.__wbg_get_contenttypeid_versionMinor(this.__wbg_ptr);
|
|
921
|
-
return ret >>> 0;
|
|
922
|
-
}
|
|
923
|
-
/**
|
|
924
|
-
* @param {number} arg0
|
|
925
|
-
*/
|
|
926
|
-
set versionMinor(arg0) {
|
|
927
|
-
wasm.__wbg_set_contenttypeid_versionMinor(this.__wbg_ptr, arg0);
|
|
928
|
-
}
|
|
929
|
-
/**
|
|
930
|
-
* @param {string} authority_id
|
|
931
|
-
* @param {string} type_id
|
|
932
|
-
* @param {number} version_major
|
|
933
|
-
* @param {number} version_minor
|
|
934
|
-
*/
|
|
935
|
-
constructor(authority_id, type_id, version_major, version_minor) {
|
|
936
|
-
const ptr0 = passStringToWasm0(authority_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
937
|
-
const len0 = WASM_VECTOR_LEN;
|
|
938
|
-
const ptr1 = passStringToWasm0(type_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
939
|
-
const len1 = WASM_VECTOR_LEN;
|
|
940
|
-
const ret = wasm.contenttypeid_new(ptr0, len0, ptr1, len1, version_major, version_minor);
|
|
941
|
-
this.__wbg_ptr = ret >>> 0;
|
|
942
|
-
ContentTypeIdFinalization.register(this, this.__wbg_ptr, this);
|
|
943
|
-
return this;
|
|
944
|
-
}
|
|
945
|
-
}
|
|
946
|
-
|
|
947
|
-
const ConversationFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
948
|
-
? { register: () => {}, unregister: () => {} }
|
|
949
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_conversation_free(ptr >>> 0, 1));
|
|
950
|
-
|
|
951
|
-
export class Conversation {
|
|
952
|
-
|
|
953
|
-
static __wrap(ptr) {
|
|
954
|
-
ptr = ptr >>> 0;
|
|
955
|
-
const obj = Object.create(Conversation.prototype);
|
|
956
|
-
obj.__wbg_ptr = ptr;
|
|
957
|
-
ConversationFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
958
|
-
return obj;
|
|
959
|
-
}
|
|
960
|
-
|
|
961
|
-
__destroy_into_raw() {
|
|
962
|
-
const ptr = this.__wbg_ptr;
|
|
963
|
-
this.__wbg_ptr = 0;
|
|
964
|
-
ConversationFinalization.unregister(this);
|
|
965
|
-
return ptr;
|
|
966
|
-
}
|
|
967
|
-
|
|
968
|
-
free() {
|
|
969
|
-
const ptr = this.__destroy_into_raw();
|
|
970
|
-
wasm.__wbg_conversation_free(ptr, 0);
|
|
971
|
-
}
|
|
972
|
-
/**
|
|
973
|
-
* @returns {ConsentState}
|
|
974
|
-
*/
|
|
975
|
-
consentState() {
|
|
976
|
-
const ret = wasm.conversation_consentState(this.__wbg_ptr);
|
|
977
|
-
if (ret[2]) {
|
|
978
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
979
|
-
}
|
|
980
|
-
return ret[0];
|
|
981
|
-
}
|
|
982
|
-
/**
|
|
983
|
-
* @param {ConsentState} state
|
|
984
|
-
*/
|
|
985
|
-
updateConsentState(state) {
|
|
986
|
-
const ret = wasm.conversation_updateConsentState(this.__wbg_ptr, state);
|
|
987
|
-
if (ret[1]) {
|
|
988
|
-
throw takeFromExternrefTable0(ret[0]);
|
|
989
|
-
}
|
|
990
|
-
}
|
|
991
|
-
/**
|
|
992
|
-
* @returns {string}
|
|
993
|
-
*/
|
|
994
|
-
id() {
|
|
995
|
-
let deferred1_0;
|
|
996
|
-
let deferred1_1;
|
|
997
|
-
try {
|
|
998
|
-
const ret = wasm.conversation_id(this.__wbg_ptr);
|
|
999
|
-
deferred1_0 = ret[0];
|
|
1000
|
-
deferred1_1 = ret[1];
|
|
1001
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
1002
|
-
} finally {
|
|
1003
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
1004
|
-
}
|
|
1005
|
-
}
|
|
1006
|
-
/**
|
|
1007
|
-
* @param {EncodedContent} encoded_content
|
|
1008
|
-
* @returns {Promise<string>}
|
|
1009
|
-
*/
|
|
1010
|
-
send(encoded_content) {
|
|
1011
|
-
_assertClass(encoded_content, EncodedContent);
|
|
1012
|
-
var ptr0 = encoded_content.__destroy_into_raw();
|
|
1013
|
-
const ret = wasm.conversation_send(this.__wbg_ptr, ptr0);
|
|
1014
|
-
return ret;
|
|
1015
|
-
}
|
|
1016
|
-
/**
|
|
1017
|
-
* send a message without immediately publishing to the delivery service.
|
|
1018
|
-
* @param {EncodedContent} encoded_content
|
|
1019
|
-
* @returns {string}
|
|
1020
|
-
*/
|
|
1021
|
-
sendOptimistic(encoded_content) {
|
|
1022
|
-
let deferred3_0;
|
|
1023
|
-
let deferred3_1;
|
|
1024
|
-
try {
|
|
1025
|
-
_assertClass(encoded_content, EncodedContent);
|
|
1026
|
-
var ptr0 = encoded_content.__destroy_into_raw();
|
|
1027
|
-
const ret = wasm.conversation_sendOptimistic(this.__wbg_ptr, ptr0);
|
|
1028
|
-
var ptr2 = ret[0];
|
|
1029
|
-
var len2 = ret[1];
|
|
1030
|
-
if (ret[3]) {
|
|
1031
|
-
ptr2 = 0; len2 = 0;
|
|
1032
|
-
throw takeFromExternrefTable0(ret[2]);
|
|
1033
|
-
}
|
|
1034
|
-
deferred3_0 = ptr2;
|
|
1035
|
-
deferred3_1 = len2;
|
|
1036
|
-
return getStringFromWasm0(ptr2, len2);
|
|
1037
|
-
} finally {
|
|
1038
|
-
wasm.__wbindgen_free(deferred3_0, deferred3_1, 1);
|
|
1039
|
-
}
|
|
1040
|
-
}
|
|
1041
|
-
/**
|
|
1042
|
-
* Publish all unpublished messages
|
|
1043
|
-
* @returns {Promise<void>}
|
|
1044
|
-
*/
|
|
1045
|
-
publishMessages() {
|
|
1046
|
-
const ret = wasm.conversation_publishMessages(this.__wbg_ptr);
|
|
1047
|
-
return ret;
|
|
1048
|
-
}
|
|
1049
|
-
/**
|
|
1050
|
-
* @returns {Promise<void>}
|
|
1051
|
-
*/
|
|
1052
|
-
sync() {
|
|
1053
|
-
const ret = wasm.conversation_sync(this.__wbg_ptr);
|
|
1054
|
-
return ret;
|
|
1055
|
-
}
|
|
1056
|
-
/**
|
|
1057
|
-
* @param {ListMessagesOptions | null} [opts]
|
|
1058
|
-
* @returns {Promise<Message[]>}
|
|
1059
|
-
*/
|
|
1060
|
-
findMessages(opts) {
|
|
1061
|
-
let ptr0 = 0;
|
|
1062
|
-
if (!isLikeNone(opts)) {
|
|
1063
|
-
_assertClass(opts, ListMessagesOptions);
|
|
1064
|
-
ptr0 = opts.__destroy_into_raw();
|
|
1065
|
-
}
|
|
1066
|
-
const ret = wasm.conversation_findMessages(this.__wbg_ptr, ptr0);
|
|
1067
|
-
return ret;
|
|
1068
|
-
}
|
|
1069
|
-
/**
|
|
1070
|
-
* @returns {Promise<any>}
|
|
1071
|
-
*/
|
|
1072
|
-
listMembers() {
|
|
1073
|
-
const ret = wasm.conversation_listMembers(this.__wbg_ptr);
|
|
1074
|
-
return ret;
|
|
1075
|
-
}
|
|
1076
|
-
/**
|
|
1077
|
-
* @returns {string[]}
|
|
1078
|
-
*/
|
|
1079
|
-
adminList() {
|
|
1080
|
-
const ret = wasm.conversation_adminList(this.__wbg_ptr);
|
|
1081
|
-
if (ret[3]) {
|
|
1082
|
-
throw takeFromExternrefTable0(ret[2]);
|
|
1083
|
-
}
|
|
1084
|
-
var v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
|
|
1085
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
1086
|
-
return v1;
|
|
1087
|
-
}
|
|
1088
|
-
/**
|
|
1089
|
-
* @returns {string[]}
|
|
1090
|
-
*/
|
|
1091
|
-
superAdminList() {
|
|
1092
|
-
const ret = wasm.conversation_superAdminList(this.__wbg_ptr);
|
|
1093
|
-
if (ret[3]) {
|
|
1094
|
-
throw takeFromExternrefTable0(ret[2]);
|
|
1095
|
-
}
|
|
1096
|
-
var v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
|
|
1097
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
1098
|
-
return v1;
|
|
1099
|
-
}
|
|
1100
|
-
/**
|
|
1101
|
-
* @param {string} inbox_id
|
|
1102
|
-
* @returns {boolean}
|
|
1103
|
-
*/
|
|
1104
|
-
isAdmin(inbox_id) {
|
|
1105
|
-
const ptr0 = passStringToWasm0(inbox_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1106
|
-
const len0 = WASM_VECTOR_LEN;
|
|
1107
|
-
const ret = wasm.conversation_isAdmin(this.__wbg_ptr, ptr0, len0);
|
|
1108
|
-
if (ret[2]) {
|
|
1109
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
1110
|
-
}
|
|
1111
|
-
return ret[0] !== 0;
|
|
1112
|
-
}
|
|
1113
|
-
/**
|
|
1114
|
-
* @param {string} inbox_id
|
|
1115
|
-
* @returns {boolean}
|
|
1116
|
-
*/
|
|
1117
|
-
isSuperAdmin(inbox_id) {
|
|
1118
|
-
const ptr0 = passStringToWasm0(inbox_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1119
|
-
const len0 = WASM_VECTOR_LEN;
|
|
1120
|
-
const ret = wasm.conversation_isSuperAdmin(this.__wbg_ptr, ptr0, len0);
|
|
1121
|
-
if (ret[2]) {
|
|
1122
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
1123
|
-
}
|
|
1124
|
-
return ret[0] !== 0;
|
|
1125
|
-
}
|
|
1126
|
-
/**
|
|
1127
|
-
* @param {string[]} account_addresses
|
|
1128
|
-
* @returns {Promise<void>}
|
|
1129
|
-
*/
|
|
1130
|
-
addMembers(account_addresses) {
|
|
1131
|
-
const ptr0 = passArrayJsValueToWasm0(account_addresses, wasm.__wbindgen_malloc);
|
|
1132
|
-
const len0 = WASM_VECTOR_LEN;
|
|
1133
|
-
const ret = wasm.conversation_addMembers(this.__wbg_ptr, ptr0, len0);
|
|
1134
|
-
return ret;
|
|
1135
|
-
}
|
|
1136
|
-
/**
|
|
1137
|
-
* @param {string} inbox_id
|
|
1138
|
-
* @returns {Promise<void>}
|
|
1139
|
-
*/
|
|
1140
|
-
addAdmin(inbox_id) {
|
|
1141
|
-
const ptr0 = passStringToWasm0(inbox_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1142
|
-
const len0 = WASM_VECTOR_LEN;
|
|
1143
|
-
const ret = wasm.conversation_addAdmin(this.__wbg_ptr, ptr0, len0);
|
|
1144
|
-
return ret;
|
|
1145
|
-
}
|
|
1146
|
-
/**
|
|
1147
|
-
* @param {string} inbox_id
|
|
1148
|
-
* @returns {Promise<void>}
|
|
1149
|
-
*/
|
|
1150
|
-
removeAdmin(inbox_id) {
|
|
1151
|
-
const ptr0 = passStringToWasm0(inbox_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1152
|
-
const len0 = WASM_VECTOR_LEN;
|
|
1153
|
-
const ret = wasm.conversation_removeAdmin(this.__wbg_ptr, ptr0, len0);
|
|
1154
|
-
return ret;
|
|
1155
|
-
}
|
|
1156
|
-
/**
|
|
1157
|
-
* @param {string} inbox_id
|
|
1158
|
-
* @returns {Promise<void>}
|
|
1159
|
-
*/
|
|
1160
|
-
addSuperAdmin(inbox_id) {
|
|
1161
|
-
const ptr0 = passStringToWasm0(inbox_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1162
|
-
const len0 = WASM_VECTOR_LEN;
|
|
1163
|
-
const ret = wasm.conversation_addSuperAdmin(this.__wbg_ptr, ptr0, len0);
|
|
1164
|
-
return ret;
|
|
1165
|
-
}
|
|
1166
|
-
/**
|
|
1167
|
-
* @param {string} inbox_id
|
|
1168
|
-
* @returns {Promise<void>}
|
|
1169
|
-
*/
|
|
1170
|
-
removeSuperAdmin(inbox_id) {
|
|
1171
|
-
const ptr0 = passStringToWasm0(inbox_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1172
|
-
const len0 = WASM_VECTOR_LEN;
|
|
1173
|
-
const ret = wasm.conversation_removeSuperAdmin(this.__wbg_ptr, ptr0, len0);
|
|
1174
|
-
return ret;
|
|
1175
|
-
}
|
|
1176
|
-
/**
|
|
1177
|
-
* @returns {GroupPermissions}
|
|
1178
|
-
*/
|
|
1179
|
-
groupPermissions() {
|
|
1180
|
-
const ret = wasm.conversation_groupPermissions(this.__wbg_ptr);
|
|
1181
|
-
if (ret[2]) {
|
|
1182
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
1183
|
-
}
|
|
1184
|
-
return GroupPermissions.__wrap(ret[0]);
|
|
1185
|
-
}
|
|
1186
|
-
/**
|
|
1187
|
-
* @param {string[]} inbox_ids
|
|
1188
|
-
* @returns {Promise<void>}
|
|
1189
|
-
*/
|
|
1190
|
-
addMembersByInboxId(inbox_ids) {
|
|
1191
|
-
const ptr0 = passArrayJsValueToWasm0(inbox_ids, wasm.__wbindgen_malloc);
|
|
1192
|
-
const len0 = WASM_VECTOR_LEN;
|
|
1193
|
-
const ret = wasm.conversation_addMembersByInboxId(this.__wbg_ptr, ptr0, len0);
|
|
1194
|
-
return ret;
|
|
1195
|
-
}
|
|
1196
|
-
/**
|
|
1197
|
-
* @param {string[]} account_addresses
|
|
1198
|
-
* @returns {Promise<void>}
|
|
1199
|
-
*/
|
|
1200
|
-
removeMembers(account_addresses) {
|
|
1201
|
-
const ptr0 = passArrayJsValueToWasm0(account_addresses, wasm.__wbindgen_malloc);
|
|
1202
|
-
const len0 = WASM_VECTOR_LEN;
|
|
1203
|
-
const ret = wasm.conversation_removeMembers(this.__wbg_ptr, ptr0, len0);
|
|
1204
|
-
return ret;
|
|
1205
|
-
}
|
|
1206
|
-
/**
|
|
1207
|
-
* @param {string[]} inbox_ids
|
|
1208
|
-
* @returns {Promise<void>}
|
|
1209
|
-
*/
|
|
1210
|
-
removeMembersByInboxId(inbox_ids) {
|
|
1211
|
-
const ptr0 = passArrayJsValueToWasm0(inbox_ids, wasm.__wbindgen_malloc);
|
|
1212
|
-
const len0 = WASM_VECTOR_LEN;
|
|
1213
|
-
const ret = wasm.conversation_removeMembersByInboxId(this.__wbg_ptr, ptr0, len0);
|
|
1214
|
-
return ret;
|
|
1215
|
-
}
|
|
1216
|
-
/**
|
|
1217
|
-
* @param {string} group_name
|
|
1218
|
-
* @returns {Promise<void>}
|
|
1219
|
-
*/
|
|
1220
|
-
updateGroupName(group_name) {
|
|
1221
|
-
const ptr0 = passStringToWasm0(group_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1222
|
-
const len0 = WASM_VECTOR_LEN;
|
|
1223
|
-
const ret = wasm.conversation_updateGroupName(this.__wbg_ptr, ptr0, len0);
|
|
1224
|
-
return ret;
|
|
1225
|
-
}
|
|
1226
|
-
/**
|
|
1227
|
-
* @returns {string}
|
|
1228
|
-
*/
|
|
1229
|
-
groupName() {
|
|
1230
|
-
let deferred2_0;
|
|
1231
|
-
let deferred2_1;
|
|
1232
|
-
try {
|
|
1233
|
-
const ret = wasm.conversation_groupName(this.__wbg_ptr);
|
|
1234
|
-
var ptr1 = ret[0];
|
|
1235
|
-
var len1 = ret[1];
|
|
1236
|
-
if (ret[3]) {
|
|
1237
|
-
ptr1 = 0; len1 = 0;
|
|
1238
|
-
throw takeFromExternrefTable0(ret[2]);
|
|
1239
|
-
}
|
|
1240
|
-
deferred2_0 = ptr1;
|
|
1241
|
-
deferred2_1 = len1;
|
|
1242
|
-
return getStringFromWasm0(ptr1, len1);
|
|
1243
|
-
} finally {
|
|
1244
|
-
wasm.__wbindgen_free(deferred2_0, deferred2_1, 1);
|
|
1245
|
-
}
|
|
1246
|
-
}
|
|
1247
|
-
/**
|
|
1248
|
-
* @param {string} group_image_url_square
|
|
1249
|
-
* @returns {Promise<void>}
|
|
1250
|
-
*/
|
|
1251
|
-
updateGroupImageUrlSquare(group_image_url_square) {
|
|
1252
|
-
const ptr0 = passStringToWasm0(group_image_url_square, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1253
|
-
const len0 = WASM_VECTOR_LEN;
|
|
1254
|
-
const ret = wasm.conversation_updateGroupImageUrlSquare(this.__wbg_ptr, ptr0, len0);
|
|
1255
|
-
return ret;
|
|
1256
|
-
}
|
|
1257
|
-
/**
|
|
1258
|
-
* @returns {string}
|
|
1259
|
-
*/
|
|
1260
|
-
groupImageUrlSquare() {
|
|
1261
|
-
let deferred2_0;
|
|
1262
|
-
let deferred2_1;
|
|
1263
|
-
try {
|
|
1264
|
-
const ret = wasm.conversation_groupImageUrlSquare(this.__wbg_ptr);
|
|
1265
|
-
var ptr1 = ret[0];
|
|
1266
|
-
var len1 = ret[1];
|
|
1267
|
-
if (ret[3]) {
|
|
1268
|
-
ptr1 = 0; len1 = 0;
|
|
1269
|
-
throw takeFromExternrefTable0(ret[2]);
|
|
1270
|
-
}
|
|
1271
|
-
deferred2_0 = ptr1;
|
|
1272
|
-
deferred2_1 = len1;
|
|
1273
|
-
return getStringFromWasm0(ptr1, len1);
|
|
1274
|
-
} finally {
|
|
1275
|
-
wasm.__wbindgen_free(deferred2_0, deferred2_1, 1);
|
|
1276
|
-
}
|
|
1277
|
-
}
|
|
1278
|
-
/**
|
|
1279
|
-
* @param {string} group_description
|
|
1280
|
-
* @returns {Promise<void>}
|
|
1281
|
-
*/
|
|
1282
|
-
updateGroupDescription(group_description) {
|
|
1283
|
-
const ptr0 = passStringToWasm0(group_description, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1284
|
-
const len0 = WASM_VECTOR_LEN;
|
|
1285
|
-
const ret = wasm.conversation_updateGroupDescription(this.__wbg_ptr, ptr0, len0);
|
|
1286
|
-
return ret;
|
|
1287
|
-
}
|
|
1288
|
-
/**
|
|
1289
|
-
* @returns {string}
|
|
1290
|
-
*/
|
|
1291
|
-
groupDescription() {
|
|
1292
|
-
let deferred2_0;
|
|
1293
|
-
let deferred2_1;
|
|
1294
|
-
try {
|
|
1295
|
-
const ret = wasm.conversation_groupDescription(this.__wbg_ptr);
|
|
1296
|
-
var ptr1 = ret[0];
|
|
1297
|
-
var len1 = ret[1];
|
|
1298
|
-
if (ret[3]) {
|
|
1299
|
-
ptr1 = 0; len1 = 0;
|
|
1300
|
-
throw takeFromExternrefTable0(ret[2]);
|
|
1301
|
-
}
|
|
1302
|
-
deferred2_0 = ptr1;
|
|
1303
|
-
deferred2_1 = len1;
|
|
1304
|
-
return getStringFromWasm0(ptr1, len1);
|
|
1305
|
-
} finally {
|
|
1306
|
-
wasm.__wbindgen_free(deferred2_0, deferred2_1, 1);
|
|
1307
|
-
}
|
|
1308
|
-
}
|
|
1309
|
-
/**
|
|
1310
|
-
* @param {any} callback
|
|
1311
|
-
* @returns {StreamCloser}
|
|
1312
|
-
*/
|
|
1313
|
-
stream(callback) {
|
|
1314
|
-
const ret = wasm.conversation_stream(this.__wbg_ptr, callback);
|
|
1315
|
-
if (ret[2]) {
|
|
1316
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
1317
|
-
}
|
|
1318
|
-
return StreamCloser.__wrap(ret[0]);
|
|
1319
|
-
}
|
|
1320
|
-
/**
|
|
1321
|
-
* @returns {bigint}
|
|
1322
|
-
*/
|
|
1323
|
-
createdAtNs() {
|
|
1324
|
-
const ret = wasm.conversation_createdAtNs(this.__wbg_ptr);
|
|
1325
|
-
return ret;
|
|
1326
|
-
}
|
|
1327
|
-
/**
|
|
1328
|
-
* @returns {boolean}
|
|
1329
|
-
*/
|
|
1330
|
-
isActive() {
|
|
1331
|
-
const ret = wasm.conversation_isActive(this.__wbg_ptr);
|
|
1332
|
-
if (ret[2]) {
|
|
1333
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
1334
|
-
}
|
|
1335
|
-
return ret[0] !== 0;
|
|
1336
|
-
}
|
|
1337
|
-
/**
|
|
1338
|
-
* @returns {string}
|
|
1339
|
-
*/
|
|
1340
|
-
addedByInboxId() {
|
|
1341
|
-
let deferred2_0;
|
|
1342
|
-
let deferred2_1;
|
|
1343
|
-
try {
|
|
1344
|
-
const ret = wasm.conversation_addedByInboxId(this.__wbg_ptr);
|
|
1345
|
-
var ptr1 = ret[0];
|
|
1346
|
-
var len1 = ret[1];
|
|
1347
|
-
if (ret[3]) {
|
|
1348
|
-
ptr1 = 0; len1 = 0;
|
|
1349
|
-
throw takeFromExternrefTable0(ret[2]);
|
|
1350
|
-
}
|
|
1351
|
-
deferred2_0 = ptr1;
|
|
1352
|
-
deferred2_1 = len1;
|
|
1353
|
-
return getStringFromWasm0(ptr1, len1);
|
|
1354
|
-
} finally {
|
|
1355
|
-
wasm.__wbindgen_free(deferred2_0, deferred2_1, 1);
|
|
1356
|
-
}
|
|
1357
|
-
}
|
|
1358
|
-
/**
|
|
1359
|
-
* @returns {Promise<GroupMetadata>}
|
|
1360
|
-
*/
|
|
1361
|
-
groupMetadata() {
|
|
1362
|
-
const ret = wasm.conversation_groupMetadata(this.__wbg_ptr);
|
|
1363
|
-
return ret;
|
|
1364
|
-
}
|
|
1365
|
-
/**
|
|
1366
|
-
* @returns {string}
|
|
1367
|
-
*/
|
|
1368
|
-
dmPeerInboxId() {
|
|
1369
|
-
let deferred2_0;
|
|
1370
|
-
let deferred2_1;
|
|
1371
|
-
try {
|
|
1372
|
-
const ret = wasm.conversation_dmPeerInboxId(this.__wbg_ptr);
|
|
1373
|
-
var ptr1 = ret[0];
|
|
1374
|
-
var len1 = ret[1];
|
|
1375
|
-
if (ret[3]) {
|
|
1376
|
-
ptr1 = 0; len1 = 0;
|
|
1377
|
-
throw takeFromExternrefTable0(ret[2]);
|
|
1378
|
-
}
|
|
1379
|
-
deferred2_0 = ptr1;
|
|
1380
|
-
deferred2_1 = len1;
|
|
1381
|
-
return getStringFromWasm0(ptr1, len1);
|
|
1382
|
-
} finally {
|
|
1383
|
-
wasm.__wbindgen_free(deferred2_0, deferred2_1, 1);
|
|
1384
|
-
}
|
|
1385
|
-
}
|
|
1386
|
-
/**
|
|
1387
|
-
* @param {PermissionUpdateType} permission_update_type
|
|
1388
|
-
* @param {PermissionPolicy} permission_policy_option
|
|
1389
|
-
* @param {MetadataField | null} [metadata_field]
|
|
1390
|
-
* @returns {Promise<void>}
|
|
1391
|
-
*/
|
|
1392
|
-
updatePermissionPolicy(permission_update_type, permission_policy_option, metadata_field) {
|
|
1393
|
-
const ret = wasm.conversation_updatePermissionPolicy(this.__wbg_ptr, permission_update_type, permission_policy_option, isLikeNone(metadata_field) ? 5 : metadata_field);
|
|
1394
|
-
return ret;
|
|
1395
|
-
}
|
|
1396
|
-
}
|
|
1397
|
-
|
|
1398
|
-
const ConversationListItemFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1399
|
-
? { register: () => {}, unregister: () => {} }
|
|
1400
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_conversationlistitem_free(ptr >>> 0, 1));
|
|
1401
|
-
|
|
1402
|
-
export class ConversationListItem {
|
|
1403
|
-
|
|
1404
|
-
static __wrap(ptr) {
|
|
1405
|
-
ptr = ptr >>> 0;
|
|
1406
|
-
const obj = Object.create(ConversationListItem.prototype);
|
|
1407
|
-
obj.__wbg_ptr = ptr;
|
|
1408
|
-
ConversationListItemFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
1409
|
-
return obj;
|
|
1410
|
-
}
|
|
1411
|
-
|
|
1412
|
-
__destroy_into_raw() {
|
|
1413
|
-
const ptr = this.__wbg_ptr;
|
|
1414
|
-
this.__wbg_ptr = 0;
|
|
1415
|
-
ConversationListItemFinalization.unregister(this);
|
|
1416
|
-
return ptr;
|
|
1417
|
-
}
|
|
1418
|
-
|
|
1419
|
-
free() {
|
|
1420
|
-
const ptr = this.__destroy_into_raw();
|
|
1421
|
-
wasm.__wbg_conversationlistitem_free(ptr, 0);
|
|
1422
|
-
}
|
|
1423
|
-
/**
|
|
1424
|
-
* @returns {Conversation}
|
|
1425
|
-
*/
|
|
1426
|
-
get conversation() {
|
|
1427
|
-
const ret = wasm.__wbg_get_conversationlistitem_conversation(this.__wbg_ptr);
|
|
1428
|
-
return Conversation.__wrap(ret);
|
|
1429
|
-
}
|
|
1430
|
-
/**
|
|
1431
|
-
* @param {Conversation} arg0
|
|
1432
|
-
*/
|
|
1433
|
-
set conversation(arg0) {
|
|
1434
|
-
_assertClass(arg0, Conversation);
|
|
1435
|
-
var ptr0 = arg0.__destroy_into_raw();
|
|
1436
|
-
wasm.__wbg_set_conversationlistitem_conversation(this.__wbg_ptr, ptr0);
|
|
1437
|
-
}
|
|
1438
|
-
/**
|
|
1439
|
-
* @returns {Message | undefined}
|
|
1440
|
-
*/
|
|
1441
|
-
get lastMessage() {
|
|
1442
|
-
const ret = wasm.__wbg_get_conversationlistitem_lastMessage(this.__wbg_ptr);
|
|
1443
|
-
return ret === 0 ? undefined : Message.__wrap(ret);
|
|
1444
|
-
}
|
|
1445
|
-
/**
|
|
1446
|
-
* @param {Message | null} [arg0]
|
|
1447
|
-
*/
|
|
1448
|
-
set lastMessage(arg0) {
|
|
1449
|
-
let ptr0 = 0;
|
|
1450
|
-
if (!isLikeNone(arg0)) {
|
|
1451
|
-
_assertClass(arg0, Message);
|
|
1452
|
-
ptr0 = arg0.__destroy_into_raw();
|
|
1453
|
-
}
|
|
1454
|
-
wasm.__wbg_set_conversationlistitem_lastMessage(this.__wbg_ptr, ptr0);
|
|
1455
|
-
}
|
|
1456
|
-
/**
|
|
1457
|
-
* @param {Conversation} conversation
|
|
1458
|
-
* @param {Message | null} [last_message]
|
|
1459
|
-
*/
|
|
1460
|
-
constructor(conversation, last_message) {
|
|
1461
|
-
_assertClass(conversation, Conversation);
|
|
1462
|
-
var ptr0 = conversation.__destroy_into_raw();
|
|
1463
|
-
let ptr1 = 0;
|
|
1464
|
-
if (!isLikeNone(last_message)) {
|
|
1465
|
-
_assertClass(last_message, Message);
|
|
1466
|
-
ptr1 = last_message.__destroy_into_raw();
|
|
1467
|
-
}
|
|
1468
|
-
const ret = wasm.conversationlistitem_new(ptr0, ptr1);
|
|
1469
|
-
this.__wbg_ptr = ret >>> 0;
|
|
1470
|
-
ConversationListItemFinalization.register(this, this.__wbg_ptr, this);
|
|
1471
|
-
return this;
|
|
1472
|
-
}
|
|
1473
|
-
}
|
|
1474
|
-
|
|
1475
|
-
const ConversationsFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1476
|
-
? { register: () => {}, unregister: () => {} }
|
|
1477
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_conversations_free(ptr >>> 0, 1));
|
|
1478
|
-
|
|
1479
|
-
export class Conversations {
|
|
1480
|
-
|
|
1481
|
-
static __wrap(ptr) {
|
|
1482
|
-
ptr = ptr >>> 0;
|
|
1483
|
-
const obj = Object.create(Conversations.prototype);
|
|
1484
|
-
obj.__wbg_ptr = ptr;
|
|
1485
|
-
ConversationsFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
1486
|
-
return obj;
|
|
1487
|
-
}
|
|
1488
|
-
|
|
1489
|
-
__destroy_into_raw() {
|
|
1490
|
-
const ptr = this.__wbg_ptr;
|
|
1491
|
-
this.__wbg_ptr = 0;
|
|
1492
|
-
ConversationsFinalization.unregister(this);
|
|
1493
|
-
return ptr;
|
|
1494
|
-
}
|
|
1495
|
-
|
|
1496
|
-
free() {
|
|
1497
|
-
const ptr = this.__destroy_into_raw();
|
|
1498
|
-
wasm.__wbg_conversations_free(ptr, 0);
|
|
1499
|
-
}
|
|
1500
|
-
/**
|
|
1501
|
-
* @param {string[]} account_addresses
|
|
1502
|
-
* @param {CreateGroupOptions | null} [options]
|
|
1503
|
-
* @returns {Promise<Conversation>}
|
|
1504
|
-
*/
|
|
1505
|
-
createGroup(account_addresses, options) {
|
|
1506
|
-
const ptr0 = passArrayJsValueToWasm0(account_addresses, wasm.__wbindgen_malloc);
|
|
1507
|
-
const len0 = WASM_VECTOR_LEN;
|
|
1508
|
-
let ptr1 = 0;
|
|
1509
|
-
if (!isLikeNone(options)) {
|
|
1510
|
-
_assertClass(options, CreateGroupOptions);
|
|
1511
|
-
ptr1 = options.__destroy_into_raw();
|
|
1512
|
-
}
|
|
1513
|
-
const ret = wasm.conversations_createGroup(this.__wbg_ptr, ptr0, len0, ptr1);
|
|
1514
|
-
return ret;
|
|
1515
|
-
}
|
|
1516
|
-
/**
|
|
1517
|
-
* @param {string[]} inbox_ids
|
|
1518
|
-
* @param {CreateGroupOptions | null} [options]
|
|
1519
|
-
* @returns {Promise<Conversation>}
|
|
1520
|
-
*/
|
|
1521
|
-
createGroupByInboxIds(inbox_ids, options) {
|
|
1522
|
-
const ptr0 = passArrayJsValueToWasm0(inbox_ids, wasm.__wbindgen_malloc);
|
|
1523
|
-
const len0 = WASM_VECTOR_LEN;
|
|
1524
|
-
let ptr1 = 0;
|
|
1525
|
-
if (!isLikeNone(options)) {
|
|
1526
|
-
_assertClass(options, CreateGroupOptions);
|
|
1527
|
-
ptr1 = options.__destroy_into_raw();
|
|
1528
|
-
}
|
|
1529
|
-
const ret = wasm.conversations_createGroupByInboxIds(this.__wbg_ptr, ptr0, len0, ptr1);
|
|
1530
|
-
return ret;
|
|
1531
|
-
}
|
|
1532
|
-
/**
|
|
1533
|
-
* @param {string} account_address
|
|
1534
|
-
* @param {CreateDMOptions | null} [options]
|
|
1535
|
-
* @returns {Promise<Conversation>}
|
|
1536
|
-
*/
|
|
1537
|
-
createDm(account_address, options) {
|
|
1538
|
-
const ptr0 = passStringToWasm0(account_address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1539
|
-
const len0 = WASM_VECTOR_LEN;
|
|
1540
|
-
let ptr1 = 0;
|
|
1541
|
-
if (!isLikeNone(options)) {
|
|
1542
|
-
_assertClass(options, CreateDMOptions);
|
|
1543
|
-
ptr1 = options.__destroy_into_raw();
|
|
1544
|
-
}
|
|
1545
|
-
const ret = wasm.conversations_createDm(this.__wbg_ptr, ptr0, len0, ptr1);
|
|
1546
|
-
return ret;
|
|
1547
|
-
}
|
|
1548
|
-
/**
|
|
1549
|
-
* @param {string} inbox_id
|
|
1550
|
-
* @param {CreateDMOptions | null} [options]
|
|
1551
|
-
* @returns {Promise<Conversation>}
|
|
1552
|
-
*/
|
|
1553
|
-
createDmByInboxId(inbox_id, options) {
|
|
1554
|
-
const ptr0 = passStringToWasm0(inbox_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1555
|
-
const len0 = WASM_VECTOR_LEN;
|
|
1556
|
-
let ptr1 = 0;
|
|
1557
|
-
if (!isLikeNone(options)) {
|
|
1558
|
-
_assertClass(options, CreateDMOptions);
|
|
1559
|
-
ptr1 = options.__destroy_into_raw();
|
|
1560
|
-
}
|
|
1561
|
-
const ret = wasm.conversations_createDmByInboxId(this.__wbg_ptr, ptr0, len0, ptr1);
|
|
1562
|
-
return ret;
|
|
1563
|
-
}
|
|
1564
|
-
/**
|
|
1565
|
-
* @param {string} group_id
|
|
1566
|
-
* @returns {Conversation}
|
|
1567
|
-
*/
|
|
1568
|
-
findGroupById(group_id) {
|
|
1569
|
-
const ptr0 = passStringToWasm0(group_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1570
|
-
const len0 = WASM_VECTOR_LEN;
|
|
1571
|
-
const ret = wasm.conversations_findGroupById(this.__wbg_ptr, ptr0, len0);
|
|
1572
|
-
if (ret[2]) {
|
|
1573
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
1574
|
-
}
|
|
1575
|
-
return Conversation.__wrap(ret[0]);
|
|
1576
|
-
}
|
|
1577
|
-
/**
|
|
1578
|
-
* @param {string} target_inbox_id
|
|
1579
|
-
* @returns {Conversation}
|
|
1580
|
-
*/
|
|
1581
|
-
findDmByTargetInboxId(target_inbox_id) {
|
|
1582
|
-
const ptr0 = passStringToWasm0(target_inbox_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1583
|
-
const len0 = WASM_VECTOR_LEN;
|
|
1584
|
-
const ret = wasm.conversations_findDmByTargetInboxId(this.__wbg_ptr, ptr0, len0);
|
|
1585
|
-
if (ret[2]) {
|
|
1586
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
1587
|
-
}
|
|
1588
|
-
return Conversation.__wrap(ret[0]);
|
|
1589
|
-
}
|
|
1590
|
-
/**
|
|
1591
|
-
* @param {string} message_id
|
|
1592
|
-
* @returns {Message}
|
|
1593
|
-
*/
|
|
1594
|
-
findMessageById(message_id) {
|
|
1595
|
-
const ptr0 = passStringToWasm0(message_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1596
|
-
const len0 = WASM_VECTOR_LEN;
|
|
1597
|
-
const ret = wasm.conversations_findMessageById(this.__wbg_ptr, ptr0, len0);
|
|
1598
|
-
if (ret[2]) {
|
|
1599
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
1600
|
-
}
|
|
1601
|
-
return Message.__wrap(ret[0]);
|
|
1602
|
-
}
|
|
1603
|
-
/**
|
|
1604
|
-
* @returns {Promise<void>}
|
|
1605
|
-
*/
|
|
1606
|
-
sync() {
|
|
1607
|
-
const ret = wasm.conversations_sync(this.__wbg_ptr);
|
|
1608
|
-
return ret;
|
|
1609
|
-
}
|
|
1610
|
-
/**
|
|
1611
|
-
* @param {any[] | null} [consent_states]
|
|
1612
|
-
* @returns {Promise<number>}
|
|
1613
|
-
*/
|
|
1614
|
-
syncAllConversations(consent_states) {
|
|
1615
|
-
var ptr0 = isLikeNone(consent_states) ? 0 : passArrayJsValueToWasm0(consent_states, wasm.__wbindgen_malloc);
|
|
1616
|
-
var len0 = WASM_VECTOR_LEN;
|
|
1617
|
-
const ret = wasm.conversations_syncAllConversations(this.__wbg_ptr, ptr0, len0);
|
|
1618
|
-
return ret;
|
|
1619
|
-
}
|
|
1620
|
-
/**
|
|
1621
|
-
* @param {ListConversationsOptions | null} [opts]
|
|
1622
|
-
* @returns {Array<any>}
|
|
1623
|
-
*/
|
|
1624
|
-
list(opts) {
|
|
1625
|
-
let ptr0 = 0;
|
|
1626
|
-
if (!isLikeNone(opts)) {
|
|
1627
|
-
_assertClass(opts, ListConversationsOptions);
|
|
1628
|
-
ptr0 = opts.__destroy_into_raw();
|
|
1629
|
-
}
|
|
1630
|
-
const ret = wasm.conversations_list(this.__wbg_ptr, ptr0);
|
|
1631
|
-
if (ret[2]) {
|
|
1632
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
1633
|
-
}
|
|
1634
|
-
return takeFromExternrefTable0(ret[0]);
|
|
1635
|
-
}
|
|
1636
|
-
/**
|
|
1637
|
-
* @param {ListConversationsOptions | null} [opts]
|
|
1638
|
-
* @returns {Array<any>}
|
|
1639
|
-
*/
|
|
1640
|
-
listGroups(opts) {
|
|
1641
|
-
let ptr0 = 0;
|
|
1642
|
-
if (!isLikeNone(opts)) {
|
|
1643
|
-
_assertClass(opts, ListConversationsOptions);
|
|
1644
|
-
ptr0 = opts.__destroy_into_raw();
|
|
1645
|
-
}
|
|
1646
|
-
const ret = wasm.conversations_listGroups(this.__wbg_ptr, ptr0);
|
|
1647
|
-
if (ret[2]) {
|
|
1648
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
1649
|
-
}
|
|
1650
|
-
return takeFromExternrefTable0(ret[0]);
|
|
1651
|
-
}
|
|
1652
|
-
/**
|
|
1653
|
-
* @param {ListConversationsOptions | null} [opts]
|
|
1654
|
-
* @returns {Array<any>}
|
|
1655
|
-
*/
|
|
1656
|
-
listDms(opts) {
|
|
1657
|
-
let ptr0 = 0;
|
|
1658
|
-
if (!isLikeNone(opts)) {
|
|
1659
|
-
_assertClass(opts, ListConversationsOptions);
|
|
1660
|
-
ptr0 = opts.__destroy_into_raw();
|
|
1661
|
-
}
|
|
1662
|
-
const ret = wasm.conversations_listDms(this.__wbg_ptr, ptr0);
|
|
1663
|
-
if (ret[2]) {
|
|
1664
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
1665
|
-
}
|
|
1666
|
-
return takeFromExternrefTable0(ret[0]);
|
|
1667
|
-
}
|
|
1668
|
-
/**
|
|
1669
|
-
* @returns {any}
|
|
1670
|
-
*/
|
|
1671
|
-
getHmacKeys() {
|
|
1672
|
-
const ret = wasm.conversations_getHmacKeys(this.__wbg_ptr);
|
|
1673
|
-
if (ret[2]) {
|
|
1674
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
1675
|
-
}
|
|
1676
|
-
return takeFromExternrefTable0(ret[0]);
|
|
1677
|
-
}
|
|
1678
|
-
/**
|
|
1679
|
-
* @param {any} callback
|
|
1680
|
-
* @param {ConversationType | null} [conversation_type]
|
|
1681
|
-
* @returns {StreamCloser}
|
|
1682
|
-
*/
|
|
1683
|
-
stream(callback, conversation_type) {
|
|
1684
|
-
const ret = wasm.conversations_stream(this.__wbg_ptr, callback, isLikeNone(conversation_type) ? 3 : conversation_type);
|
|
1685
|
-
if (ret[2]) {
|
|
1686
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
1687
|
-
}
|
|
1688
|
-
return StreamCloser.__wrap(ret[0]);
|
|
1689
|
-
}
|
|
1690
|
-
/**
|
|
1691
|
-
* @param {any} callback
|
|
1692
|
-
* @returns {StreamCloser}
|
|
1693
|
-
*/
|
|
1694
|
-
streamGroups(callback) {
|
|
1695
|
-
const ret = wasm.conversations_streamGroups(this.__wbg_ptr, callback);
|
|
1696
|
-
if (ret[2]) {
|
|
1697
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
1698
|
-
}
|
|
1699
|
-
return StreamCloser.__wrap(ret[0]);
|
|
1700
|
-
}
|
|
1701
|
-
/**
|
|
1702
|
-
* @param {any} callback
|
|
1703
|
-
* @returns {StreamCloser}
|
|
1704
|
-
*/
|
|
1705
|
-
streamDms(callback) {
|
|
1706
|
-
const ret = wasm.conversations_streamDms(this.__wbg_ptr, callback);
|
|
1707
|
-
if (ret[2]) {
|
|
1708
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
1709
|
-
}
|
|
1710
|
-
return StreamCloser.__wrap(ret[0]);
|
|
1711
|
-
}
|
|
1712
|
-
/**
|
|
1713
|
-
* @param {any} callback
|
|
1714
|
-
* @param {ConversationType | null} [conversation_type]
|
|
1715
|
-
* @returns {StreamCloser}
|
|
1716
|
-
*/
|
|
1717
|
-
streamAllMessages(callback, conversation_type) {
|
|
1718
|
-
const ret = wasm.conversations_streamAllMessages(this.__wbg_ptr, callback, isLikeNone(conversation_type) ? 3 : conversation_type);
|
|
1719
|
-
if (ret[2]) {
|
|
1720
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
1721
|
-
}
|
|
1722
|
-
return StreamCloser.__wrap(ret[0]);
|
|
1723
|
-
}
|
|
1724
|
-
}
|
|
1725
|
-
|
|
1726
|
-
const CreateDMOptionsFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1727
|
-
? { register: () => {}, unregister: () => {} }
|
|
1728
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_createdmoptions_free(ptr >>> 0, 1));
|
|
1729
|
-
|
|
1730
|
-
export class CreateDMOptions {
|
|
1731
|
-
|
|
1732
|
-
__destroy_into_raw() {
|
|
1733
|
-
const ptr = this.__wbg_ptr;
|
|
1734
|
-
this.__wbg_ptr = 0;
|
|
1735
|
-
CreateDMOptionsFinalization.unregister(this);
|
|
1736
|
-
return ptr;
|
|
1737
|
-
}
|
|
1738
|
-
|
|
1739
|
-
free() {
|
|
1740
|
-
const ptr = this.__destroy_into_raw();
|
|
1741
|
-
wasm.__wbg_createdmoptions_free(ptr, 0);
|
|
1742
|
-
}
|
|
1743
|
-
/**
|
|
1744
|
-
* @returns {MessageDisappearingSettings | undefined}
|
|
1745
|
-
*/
|
|
1746
|
-
get messageDisappearingSettings() {
|
|
1747
|
-
const ret = wasm.__wbg_get_createdmoptions_messageDisappearingSettings(this.__wbg_ptr);
|
|
1748
|
-
return ret === 0 ? undefined : MessageDisappearingSettings.__wrap(ret);
|
|
1749
|
-
}
|
|
1750
|
-
/**
|
|
1751
|
-
* @param {MessageDisappearingSettings | null} [arg0]
|
|
1752
|
-
*/
|
|
1753
|
-
set messageDisappearingSettings(arg0) {
|
|
1754
|
-
let ptr0 = 0;
|
|
1755
|
-
if (!isLikeNone(arg0)) {
|
|
1756
|
-
_assertClass(arg0, MessageDisappearingSettings);
|
|
1757
|
-
ptr0 = arg0.__destroy_into_raw();
|
|
1758
|
-
}
|
|
1759
|
-
wasm.__wbg_set_createdmoptions_messageDisappearingSettings(this.__wbg_ptr, ptr0);
|
|
1760
|
-
}
|
|
1761
|
-
/**
|
|
1762
|
-
* @param {MessageDisappearingSettings | null} [message_disappearing_settings]
|
|
1763
|
-
*/
|
|
1764
|
-
constructor(message_disappearing_settings) {
|
|
1765
|
-
let ptr0 = 0;
|
|
1766
|
-
if (!isLikeNone(message_disappearing_settings)) {
|
|
1767
|
-
_assertClass(message_disappearing_settings, MessageDisappearingSettings);
|
|
1768
|
-
ptr0 = message_disappearing_settings.__destroy_into_raw();
|
|
1769
|
-
}
|
|
1770
|
-
const ret = wasm.createdmoptions_new(ptr0);
|
|
1771
|
-
this.__wbg_ptr = ret >>> 0;
|
|
1772
|
-
CreateDMOptionsFinalization.register(this, this.__wbg_ptr, this);
|
|
1773
|
-
return this;
|
|
1774
|
-
}
|
|
1775
|
-
}
|
|
1776
|
-
|
|
1777
|
-
const CreateGroupOptionsFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1778
|
-
? { register: () => {}, unregister: () => {} }
|
|
1779
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_creategroupoptions_free(ptr >>> 0, 1));
|
|
1780
|
-
|
|
1781
|
-
export class CreateGroupOptions {
|
|
1782
|
-
|
|
1783
|
-
__destroy_into_raw() {
|
|
1784
|
-
const ptr = this.__wbg_ptr;
|
|
1785
|
-
this.__wbg_ptr = 0;
|
|
1786
|
-
CreateGroupOptionsFinalization.unregister(this);
|
|
1787
|
-
return ptr;
|
|
1788
|
-
}
|
|
1789
|
-
|
|
1790
|
-
free() {
|
|
1791
|
-
const ptr = this.__destroy_into_raw();
|
|
1792
|
-
wasm.__wbg_creategroupoptions_free(ptr, 0);
|
|
1793
|
-
}
|
|
1794
|
-
/**
|
|
1795
|
-
* @returns {GroupPermissionsOptions | undefined}
|
|
1796
|
-
*/
|
|
1797
|
-
get permissions() {
|
|
1798
|
-
const ret = wasm.__wbg_get_creategroupoptions_permissions(this.__wbg_ptr);
|
|
1799
|
-
return ret === 3 ? undefined : ret;
|
|
1800
|
-
}
|
|
1801
|
-
/**
|
|
1802
|
-
* @param {GroupPermissionsOptions | null} [arg0]
|
|
1803
|
-
*/
|
|
1804
|
-
set permissions(arg0) {
|
|
1805
|
-
wasm.__wbg_set_creategroupoptions_permissions(this.__wbg_ptr, isLikeNone(arg0) ? 3 : arg0);
|
|
1806
|
-
}
|
|
1807
|
-
/**
|
|
1808
|
-
* @returns {string | undefined}
|
|
1809
|
-
*/
|
|
1810
|
-
get groupName() {
|
|
1811
|
-
const ret = wasm.__wbg_get_creategroupoptions_groupName(this.__wbg_ptr);
|
|
1812
|
-
let v1;
|
|
1813
|
-
if (ret[0] !== 0) {
|
|
1814
|
-
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
1815
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
1816
|
-
}
|
|
1817
|
-
return v1;
|
|
1818
|
-
}
|
|
1819
|
-
/**
|
|
1820
|
-
* @param {string | null} [arg0]
|
|
1821
|
-
*/
|
|
1822
|
-
set groupName(arg0) {
|
|
1823
|
-
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1824
|
-
var len0 = WASM_VECTOR_LEN;
|
|
1825
|
-
wasm.__wbg_set_creategroupoptions_groupName(this.__wbg_ptr, ptr0, len0);
|
|
1826
|
-
}
|
|
1827
|
-
/**
|
|
1828
|
-
* @returns {string | undefined}
|
|
1829
|
-
*/
|
|
1830
|
-
get groupImageUrlSquare() {
|
|
1831
|
-
const ret = wasm.__wbg_get_creategroupoptions_groupImageUrlSquare(this.__wbg_ptr);
|
|
1832
|
-
let v1;
|
|
1833
|
-
if (ret[0] !== 0) {
|
|
1834
|
-
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
1835
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
1836
|
-
}
|
|
1837
|
-
return v1;
|
|
1838
|
-
}
|
|
1839
|
-
/**
|
|
1840
|
-
* @param {string | null} [arg0]
|
|
1841
|
-
*/
|
|
1842
|
-
set groupImageUrlSquare(arg0) {
|
|
1843
|
-
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1844
|
-
var len0 = WASM_VECTOR_LEN;
|
|
1845
|
-
wasm.__wbg_set_creategroupoptions_groupImageUrlSquare(this.__wbg_ptr, ptr0, len0);
|
|
1846
|
-
}
|
|
1847
|
-
/**
|
|
1848
|
-
* @returns {string | undefined}
|
|
1849
|
-
*/
|
|
1850
|
-
get groupDescription() {
|
|
1851
|
-
const ret = wasm.__wbg_get_creategroupoptions_groupDescription(this.__wbg_ptr);
|
|
1852
|
-
let v1;
|
|
1853
|
-
if (ret[0] !== 0) {
|
|
1854
|
-
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
1855
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
1856
|
-
}
|
|
1857
|
-
return v1;
|
|
1858
|
-
}
|
|
1859
|
-
/**
|
|
1860
|
-
* @param {string | null} [arg0]
|
|
1861
|
-
*/
|
|
1862
|
-
set groupDescription(arg0) {
|
|
1863
|
-
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1864
|
-
var len0 = WASM_VECTOR_LEN;
|
|
1865
|
-
wasm.__wbg_set_creategroupoptions_groupDescription(this.__wbg_ptr, ptr0, len0);
|
|
1866
|
-
}
|
|
1867
|
-
/**
|
|
1868
|
-
* @returns {PermissionPolicySet | undefined}
|
|
1869
|
-
*/
|
|
1870
|
-
get customPermissionPolicySet() {
|
|
1871
|
-
const ret = wasm.__wbg_get_creategroupoptions_customPermissionPolicySet(this.__wbg_ptr);
|
|
1872
|
-
return ret === 0 ? undefined : PermissionPolicySet.__wrap(ret);
|
|
1873
|
-
}
|
|
1874
|
-
/**
|
|
1875
|
-
* @param {PermissionPolicySet | null} [arg0]
|
|
1876
|
-
*/
|
|
1877
|
-
set customPermissionPolicySet(arg0) {
|
|
1878
|
-
let ptr0 = 0;
|
|
1879
|
-
if (!isLikeNone(arg0)) {
|
|
1880
|
-
_assertClass(arg0, PermissionPolicySet);
|
|
1881
|
-
ptr0 = arg0.__destroy_into_raw();
|
|
1882
|
-
}
|
|
1883
|
-
wasm.__wbg_set_creategroupoptions_customPermissionPolicySet(this.__wbg_ptr, ptr0);
|
|
1884
|
-
}
|
|
1885
|
-
/**
|
|
1886
|
-
* @returns {MessageDisappearingSettings | undefined}
|
|
1887
|
-
*/
|
|
1888
|
-
get messageDisappearingSettings() {
|
|
1889
|
-
const ret = wasm.__wbg_get_createdmoptions_messageDisappearingSettings(this.__wbg_ptr);
|
|
1890
|
-
return ret === 0 ? undefined : MessageDisappearingSettings.__wrap(ret);
|
|
1891
|
-
}
|
|
1892
|
-
/**
|
|
1893
|
-
* @param {MessageDisappearingSettings | null} [arg0]
|
|
1894
|
-
*/
|
|
1895
|
-
set messageDisappearingSettings(arg0) {
|
|
1896
|
-
let ptr0 = 0;
|
|
1897
|
-
if (!isLikeNone(arg0)) {
|
|
1898
|
-
_assertClass(arg0, MessageDisappearingSettings);
|
|
1899
|
-
ptr0 = arg0.__destroy_into_raw();
|
|
1900
|
-
}
|
|
1901
|
-
wasm.__wbg_set_createdmoptions_messageDisappearingSettings(this.__wbg_ptr, ptr0);
|
|
1902
|
-
}
|
|
1903
|
-
/**
|
|
1904
|
-
* @param {GroupPermissionsOptions | null} [permissions]
|
|
1905
|
-
* @param {string | null} [group_name]
|
|
1906
|
-
* @param {string | null} [group_image_url_square]
|
|
1907
|
-
* @param {string | null} [group_description]
|
|
1908
|
-
* @param {PermissionPolicySet | null} [custom_permission_policy_set]
|
|
1909
|
-
* @param {MessageDisappearingSettings | null} [message_disappearing_settings]
|
|
1910
|
-
*/
|
|
1911
|
-
constructor(permissions, group_name, group_image_url_square, group_description, custom_permission_policy_set, message_disappearing_settings) {
|
|
1912
|
-
var ptr0 = isLikeNone(group_name) ? 0 : passStringToWasm0(group_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1913
|
-
var len0 = WASM_VECTOR_LEN;
|
|
1914
|
-
var ptr1 = isLikeNone(group_image_url_square) ? 0 : passStringToWasm0(group_image_url_square, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1915
|
-
var len1 = WASM_VECTOR_LEN;
|
|
1916
|
-
var ptr2 = isLikeNone(group_description) ? 0 : passStringToWasm0(group_description, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1917
|
-
var len2 = WASM_VECTOR_LEN;
|
|
1918
|
-
let ptr3 = 0;
|
|
1919
|
-
if (!isLikeNone(custom_permission_policy_set)) {
|
|
1920
|
-
_assertClass(custom_permission_policy_set, PermissionPolicySet);
|
|
1921
|
-
ptr3 = custom_permission_policy_set.__destroy_into_raw();
|
|
1922
|
-
}
|
|
1923
|
-
let ptr4 = 0;
|
|
1924
|
-
if (!isLikeNone(message_disappearing_settings)) {
|
|
1925
|
-
_assertClass(message_disappearing_settings, MessageDisappearingSettings);
|
|
1926
|
-
ptr4 = message_disappearing_settings.__destroy_into_raw();
|
|
1927
|
-
}
|
|
1928
|
-
const ret = wasm.creategroupoptions_new(isLikeNone(permissions) ? 3 : permissions, ptr0, len0, ptr1, len1, ptr2, len2, ptr3, ptr4);
|
|
1929
|
-
this.__wbg_ptr = ret >>> 0;
|
|
1930
|
-
CreateGroupOptionsFinalization.register(this, this.__wbg_ptr, this);
|
|
1931
|
-
return this;
|
|
1932
|
-
}
|
|
1933
|
-
}
|
|
1934
|
-
|
|
1935
|
-
const EncodedContentFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1936
|
-
? { register: () => {}, unregister: () => {} }
|
|
1937
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_encodedcontent_free(ptr >>> 0, 1));
|
|
1938
|
-
|
|
1939
|
-
export class EncodedContent {
|
|
1940
|
-
|
|
1941
|
-
static __wrap(ptr) {
|
|
1942
|
-
ptr = ptr >>> 0;
|
|
1943
|
-
const obj = Object.create(EncodedContent.prototype);
|
|
1944
|
-
obj.__wbg_ptr = ptr;
|
|
1945
|
-
EncodedContentFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
1946
|
-
return obj;
|
|
1947
|
-
}
|
|
1948
|
-
|
|
1949
|
-
__destroy_into_raw() {
|
|
1950
|
-
const ptr = this.__wbg_ptr;
|
|
1951
|
-
this.__wbg_ptr = 0;
|
|
1952
|
-
EncodedContentFinalization.unregister(this);
|
|
1953
|
-
return ptr;
|
|
1954
|
-
}
|
|
1955
|
-
|
|
1956
|
-
free() {
|
|
1957
|
-
const ptr = this.__destroy_into_raw();
|
|
1958
|
-
wasm.__wbg_encodedcontent_free(ptr, 0);
|
|
1959
|
-
}
|
|
1960
|
-
/**
|
|
1961
|
-
* @returns {ContentTypeId | undefined}
|
|
1962
|
-
*/
|
|
1963
|
-
get type() {
|
|
1964
|
-
const ret = wasm.__wbg_get_encodedcontent_type(this.__wbg_ptr);
|
|
1965
|
-
return ret === 0 ? undefined : ContentTypeId.__wrap(ret);
|
|
1966
|
-
}
|
|
1967
|
-
/**
|
|
1968
|
-
* @param {ContentTypeId | null} [arg0]
|
|
1969
|
-
*/
|
|
1970
|
-
set type(arg0) {
|
|
1971
|
-
let ptr0 = 0;
|
|
1972
|
-
if (!isLikeNone(arg0)) {
|
|
1973
|
-
_assertClass(arg0, ContentTypeId);
|
|
1974
|
-
ptr0 = arg0.__destroy_into_raw();
|
|
1975
|
-
}
|
|
1976
|
-
wasm.__wbg_set_encodedcontent_type(this.__wbg_ptr, ptr0);
|
|
1977
|
-
}
|
|
1978
|
-
/**
|
|
1979
|
-
* @returns {any}
|
|
1980
|
-
*/
|
|
1981
|
-
get parameters() {
|
|
1982
|
-
const ret = wasm.__wbg_get_encodedcontent_parameters(this.__wbg_ptr);
|
|
1983
|
-
return ret;
|
|
1984
|
-
}
|
|
1985
|
-
/**
|
|
1986
|
-
* @param {any} arg0
|
|
1987
|
-
*/
|
|
1988
|
-
set parameters(arg0) {
|
|
1989
|
-
wasm.__wbg_set_encodedcontent_parameters(this.__wbg_ptr, arg0);
|
|
1990
|
-
}
|
|
1991
|
-
/**
|
|
1992
|
-
* @returns {string | undefined}
|
|
1993
|
-
*/
|
|
1994
|
-
get fallback() {
|
|
1995
|
-
const ret = wasm.__wbg_get_encodedcontent_fallback(this.__wbg_ptr);
|
|
1996
|
-
let v1;
|
|
1997
|
-
if (ret[0] !== 0) {
|
|
1998
|
-
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
1999
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
2000
|
-
}
|
|
2001
|
-
return v1;
|
|
2002
|
-
}
|
|
2003
|
-
/**
|
|
2004
|
-
* @param {string | null} [arg0]
|
|
2005
|
-
*/
|
|
2006
|
-
set fallback(arg0) {
|
|
2007
|
-
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
2008
|
-
var len0 = WASM_VECTOR_LEN;
|
|
2009
|
-
wasm.__wbg_set_encodedcontent_fallback(this.__wbg_ptr, ptr0, len0);
|
|
2010
|
-
}
|
|
2011
|
-
/**
|
|
2012
|
-
* @returns {number | undefined}
|
|
2013
|
-
*/
|
|
2014
|
-
get compression() {
|
|
2015
|
-
const ret = wasm.__wbg_get_encodedcontent_compression(this.__wbg_ptr);
|
|
2016
|
-
return ret === 0x100000001 ? undefined : ret;
|
|
2017
|
-
}
|
|
2018
|
-
/**
|
|
2019
|
-
* @param {number | null} [arg0]
|
|
2020
|
-
*/
|
|
2021
|
-
set compression(arg0) {
|
|
2022
|
-
wasm.__wbg_set_encodedcontent_compression(this.__wbg_ptr, isLikeNone(arg0) ? 0x100000001 : (arg0) >> 0);
|
|
2023
|
-
}
|
|
2024
|
-
/**
|
|
2025
|
-
* @returns {Uint8Array}
|
|
2026
|
-
*/
|
|
2027
|
-
get content() {
|
|
2028
|
-
const ret = wasm.__wbg_get_encodedcontent_content(this.__wbg_ptr);
|
|
2029
|
-
return ret;
|
|
2030
|
-
}
|
|
2031
|
-
/**
|
|
2032
|
-
* @param {Uint8Array} arg0
|
|
2033
|
-
*/
|
|
2034
|
-
set content(arg0) {
|
|
2035
|
-
wasm.__wbg_set_encodedcontent_content(this.__wbg_ptr, arg0);
|
|
2036
|
-
}
|
|
2037
|
-
/**
|
|
2038
|
-
* @param {ContentTypeId | null | undefined} type
|
|
2039
|
-
* @param {any} parameters
|
|
2040
|
-
* @param {string | null | undefined} fallback
|
|
2041
|
-
* @param {number | null | undefined} compression
|
|
2042
|
-
* @param {Uint8Array} content
|
|
2043
|
-
*/
|
|
2044
|
-
constructor(type, parameters, fallback, compression, content) {
|
|
2045
|
-
let ptr0 = 0;
|
|
2046
|
-
if (!isLikeNone(type)) {
|
|
2047
|
-
_assertClass(type, ContentTypeId);
|
|
2048
|
-
ptr0 = type.__destroy_into_raw();
|
|
2049
|
-
}
|
|
2050
|
-
var ptr1 = isLikeNone(fallback) ? 0 : passStringToWasm0(fallback, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
2051
|
-
var len1 = WASM_VECTOR_LEN;
|
|
2052
|
-
const ret = wasm.encodedcontent_new(ptr0, parameters, ptr1, len1, isLikeNone(compression) ? 0x100000001 : (compression) >> 0, content);
|
|
2053
|
-
this.__wbg_ptr = ret >>> 0;
|
|
2054
|
-
EncodedContentFinalization.register(this, this.__wbg_ptr, this);
|
|
2055
|
-
return this;
|
|
2056
|
-
}
|
|
2057
|
-
}
|
|
2058
|
-
|
|
2059
|
-
const GroupMemberFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
2060
|
-
? { register: () => {}, unregister: () => {} }
|
|
2061
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_groupmember_free(ptr >>> 0, 1));
|
|
2062
|
-
|
|
2063
|
-
export class GroupMember {
|
|
2064
|
-
|
|
2065
|
-
__destroy_into_raw() {
|
|
2066
|
-
const ptr = this.__wbg_ptr;
|
|
2067
|
-
this.__wbg_ptr = 0;
|
|
2068
|
-
GroupMemberFinalization.unregister(this);
|
|
2069
|
-
return ptr;
|
|
2070
|
-
}
|
|
2071
|
-
|
|
2072
|
-
free() {
|
|
2073
|
-
const ptr = this.__destroy_into_raw();
|
|
2074
|
-
wasm.__wbg_groupmember_free(ptr, 0);
|
|
2075
|
-
}
|
|
2076
|
-
/**
|
|
2077
|
-
* @returns {string}
|
|
2078
|
-
*/
|
|
2079
|
-
get inboxId() {
|
|
2080
|
-
let deferred1_0;
|
|
2081
|
-
let deferred1_1;
|
|
2082
|
-
try {
|
|
2083
|
-
const ret = wasm.__wbg_get_groupmember_inboxId(this.__wbg_ptr);
|
|
2084
|
-
deferred1_0 = ret[0];
|
|
2085
|
-
deferred1_1 = ret[1];
|
|
2086
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
2087
|
-
} finally {
|
|
2088
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
2089
|
-
}
|
|
2090
|
-
}
|
|
2091
|
-
/**
|
|
2092
|
-
* @param {string} arg0
|
|
2093
|
-
*/
|
|
2094
|
-
set inboxId(arg0) {
|
|
2095
|
-
const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
2096
|
-
const len0 = WASM_VECTOR_LEN;
|
|
2097
|
-
wasm.__wbg_set_consent_entity(this.__wbg_ptr, ptr0, len0);
|
|
2098
|
-
}
|
|
2099
|
-
/**
|
|
2100
|
-
* @returns {string[]}
|
|
2101
|
-
*/
|
|
2102
|
-
get accountAddresses() {
|
|
2103
|
-
const ret = wasm.__wbg_get_groupmember_accountAddresses(this.__wbg_ptr);
|
|
2104
|
-
var v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
|
|
2105
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
2106
|
-
return v1;
|
|
2107
|
-
}
|
|
2108
|
-
/**
|
|
2109
|
-
* @param {string[]} arg0
|
|
2110
|
-
*/
|
|
2111
|
-
set accountAddresses(arg0) {
|
|
2112
|
-
const ptr0 = passArrayJsValueToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
2113
|
-
const len0 = WASM_VECTOR_LEN;
|
|
2114
|
-
wasm.__wbg_set_groupmember_accountAddresses(this.__wbg_ptr, ptr0, len0);
|
|
2115
|
-
}
|
|
2116
|
-
/**
|
|
2117
|
-
* @returns {string[]}
|
|
2118
|
-
*/
|
|
2119
|
-
get installationIds() {
|
|
2120
|
-
const ret = wasm.__wbg_get_groupmember_installationIds(this.__wbg_ptr);
|
|
2121
|
-
var v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
|
|
2122
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
2123
|
-
return v1;
|
|
2124
|
-
}
|
|
2125
|
-
/**
|
|
2126
|
-
* @param {string[]} arg0
|
|
2127
|
-
*/
|
|
2128
|
-
set installationIds(arg0) {
|
|
2129
|
-
const ptr0 = passArrayJsValueToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
2130
|
-
const len0 = WASM_VECTOR_LEN;
|
|
2131
|
-
wasm.__wbg_set_groupmember_installationIds(this.__wbg_ptr, ptr0, len0);
|
|
2132
|
-
}
|
|
2133
|
-
/**
|
|
2134
|
-
* @returns {PermissionLevel}
|
|
2135
|
-
*/
|
|
2136
|
-
get permissionLevel() {
|
|
2137
|
-
const ret = wasm.__wbg_get_groupmember_permissionLevel(this.__wbg_ptr);
|
|
2138
|
-
return ret;
|
|
2139
|
-
}
|
|
2140
|
-
/**
|
|
2141
|
-
* @param {PermissionLevel} arg0
|
|
2142
|
-
*/
|
|
2143
|
-
set permissionLevel(arg0) {
|
|
2144
|
-
wasm.__wbg_set_groupmember_permissionLevel(this.__wbg_ptr, arg0);
|
|
2145
|
-
}
|
|
2146
|
-
/**
|
|
2147
|
-
* @returns {ConsentState}
|
|
2148
|
-
*/
|
|
2149
|
-
get consentState() {
|
|
2150
|
-
const ret = wasm.__wbg_get_groupmember_consentState(this.__wbg_ptr);
|
|
2151
|
-
return ret;
|
|
2152
|
-
}
|
|
2153
|
-
/**
|
|
2154
|
-
* @param {ConsentState} arg0
|
|
2155
|
-
*/
|
|
2156
|
-
set consentState(arg0) {
|
|
2157
|
-
wasm.__wbg_set_groupmember_consentState(this.__wbg_ptr, arg0);
|
|
2158
|
-
}
|
|
2159
|
-
/**
|
|
2160
|
-
* @param {string} inbox_id
|
|
2161
|
-
* @param {string[]} account_addresses
|
|
2162
|
-
* @param {string[]} installation_ids
|
|
2163
|
-
* @param {PermissionLevel} permission_level
|
|
2164
|
-
* @param {ConsentState} consent_state
|
|
2165
|
-
*/
|
|
2166
|
-
constructor(inbox_id, account_addresses, installation_ids, permission_level, consent_state) {
|
|
2167
|
-
const ptr0 = passStringToWasm0(inbox_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
2168
|
-
const len0 = WASM_VECTOR_LEN;
|
|
2169
|
-
const ptr1 = passArrayJsValueToWasm0(account_addresses, wasm.__wbindgen_malloc);
|
|
2170
|
-
const len1 = WASM_VECTOR_LEN;
|
|
2171
|
-
const ptr2 = passArrayJsValueToWasm0(installation_ids, wasm.__wbindgen_malloc);
|
|
2172
|
-
const len2 = WASM_VECTOR_LEN;
|
|
2173
|
-
const ret = wasm.groupmember_new(ptr0, len0, ptr1, len1, ptr2, len2, permission_level, consent_state);
|
|
2174
|
-
this.__wbg_ptr = ret >>> 0;
|
|
2175
|
-
GroupMemberFinalization.register(this, this.__wbg_ptr, this);
|
|
2176
|
-
return this;
|
|
2177
|
-
}
|
|
2178
|
-
}
|
|
2179
|
-
|
|
2180
|
-
const GroupMetadataFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
2181
|
-
? { register: () => {}, unregister: () => {} }
|
|
2182
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_groupmetadata_free(ptr >>> 0, 1));
|
|
2183
|
-
|
|
2184
|
-
export class GroupMetadata {
|
|
2185
|
-
|
|
2186
|
-
static __wrap(ptr) {
|
|
2187
|
-
ptr = ptr >>> 0;
|
|
2188
|
-
const obj = Object.create(GroupMetadata.prototype);
|
|
2189
|
-
obj.__wbg_ptr = ptr;
|
|
2190
|
-
GroupMetadataFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
2191
|
-
return obj;
|
|
2192
|
-
}
|
|
2193
|
-
|
|
2194
|
-
__destroy_into_raw() {
|
|
2195
|
-
const ptr = this.__wbg_ptr;
|
|
2196
|
-
this.__wbg_ptr = 0;
|
|
2197
|
-
GroupMetadataFinalization.unregister(this);
|
|
2198
|
-
return ptr;
|
|
2199
|
-
}
|
|
2200
|
-
|
|
2201
|
-
free() {
|
|
2202
|
-
const ptr = this.__destroy_into_raw();
|
|
2203
|
-
wasm.__wbg_groupmetadata_free(ptr, 0);
|
|
2204
|
-
}
|
|
2205
|
-
/**
|
|
2206
|
-
* @returns {string}
|
|
2207
|
-
*/
|
|
2208
|
-
creatorInboxId() {
|
|
2209
|
-
let deferred1_0;
|
|
2210
|
-
let deferred1_1;
|
|
2211
|
-
try {
|
|
2212
|
-
const ret = wasm.groupmetadata_creatorInboxId(this.__wbg_ptr);
|
|
2213
|
-
deferred1_0 = ret[0];
|
|
2214
|
-
deferred1_1 = ret[1];
|
|
2215
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
2216
|
-
} finally {
|
|
2217
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
2218
|
-
}
|
|
2219
|
-
}
|
|
2220
|
-
/**
|
|
2221
|
-
* @returns {string}
|
|
2222
|
-
*/
|
|
2223
|
-
conversationType() {
|
|
2224
|
-
let deferred1_0;
|
|
2225
|
-
let deferred1_1;
|
|
2226
|
-
try {
|
|
2227
|
-
const ret = wasm.groupmetadata_conversationType(this.__wbg_ptr);
|
|
2228
|
-
deferred1_0 = ret[0];
|
|
2229
|
-
deferred1_1 = ret[1];
|
|
2230
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
2231
|
-
} finally {
|
|
2232
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
2233
|
-
}
|
|
2234
|
-
}
|
|
2235
|
-
}
|
|
2236
|
-
|
|
2237
|
-
const GroupPermissionsFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
2238
|
-
? { register: () => {}, unregister: () => {} }
|
|
2239
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_grouppermissions_free(ptr >>> 0, 1));
|
|
2240
|
-
|
|
2241
|
-
export class GroupPermissions {
|
|
2242
|
-
|
|
2243
|
-
static __wrap(ptr) {
|
|
2244
|
-
ptr = ptr >>> 0;
|
|
2245
|
-
const obj = Object.create(GroupPermissions.prototype);
|
|
2246
|
-
obj.__wbg_ptr = ptr;
|
|
2247
|
-
GroupPermissionsFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
2248
|
-
return obj;
|
|
2249
|
-
}
|
|
2250
|
-
|
|
2251
|
-
__destroy_into_raw() {
|
|
2252
|
-
const ptr = this.__wbg_ptr;
|
|
2253
|
-
this.__wbg_ptr = 0;
|
|
2254
|
-
GroupPermissionsFinalization.unregister(this);
|
|
2255
|
-
return ptr;
|
|
2256
|
-
}
|
|
2257
|
-
|
|
2258
|
-
free() {
|
|
2259
|
-
const ptr = this.__destroy_into_raw();
|
|
2260
|
-
wasm.__wbg_grouppermissions_free(ptr, 0);
|
|
2261
|
-
}
|
|
2262
|
-
/**
|
|
2263
|
-
* @returns {GroupPermissionsOptions}
|
|
2264
|
-
*/
|
|
2265
|
-
policyType() {
|
|
2266
|
-
const ret = wasm.grouppermissions_policyType(this.__wbg_ptr);
|
|
2267
|
-
if (ret[2]) {
|
|
2268
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
2269
|
-
}
|
|
2270
|
-
return ret[0];
|
|
2271
|
-
}
|
|
2272
|
-
/**
|
|
2273
|
-
* @returns {PermissionPolicySet}
|
|
2274
|
-
*/
|
|
2275
|
-
policySet() {
|
|
2276
|
-
const ret = wasm.grouppermissions_policySet(this.__wbg_ptr);
|
|
2277
|
-
if (ret[2]) {
|
|
2278
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
2279
|
-
}
|
|
2280
|
-
return PermissionPolicySet.__wrap(ret[0]);
|
|
2281
|
-
}
|
|
2282
|
-
}
|
|
2283
|
-
|
|
2284
|
-
const HmacKeyFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
2285
|
-
? { register: () => {}, unregister: () => {} }
|
|
2286
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_hmackey_free(ptr >>> 0, 1));
|
|
2287
|
-
|
|
2288
|
-
export class HmacKey {
|
|
2289
|
-
|
|
2290
|
-
__destroy_into_raw() {
|
|
2291
|
-
const ptr = this.__wbg_ptr;
|
|
2292
|
-
this.__wbg_ptr = 0;
|
|
2293
|
-
HmacKeyFinalization.unregister(this);
|
|
2294
|
-
return ptr;
|
|
2295
|
-
}
|
|
2296
|
-
|
|
2297
|
-
free() {
|
|
2298
|
-
const ptr = this.__destroy_into_raw();
|
|
2299
|
-
wasm.__wbg_hmackey_free(ptr, 0);
|
|
2300
|
-
}
|
|
2301
|
-
/**
|
|
2302
|
-
* @returns {Uint8Array}
|
|
2303
|
-
*/
|
|
2304
|
-
get key() {
|
|
2305
|
-
const ret = wasm.__wbg_get_hmackey_key(this.__wbg_ptr);
|
|
2306
|
-
var v1 = getArrayU8FromWasm0(ret[0], ret[1]).slice();
|
|
2307
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
2308
|
-
return v1;
|
|
2309
|
-
}
|
|
2310
|
-
/**
|
|
2311
|
-
* @param {Uint8Array} arg0
|
|
2312
|
-
*/
|
|
2313
|
-
set key(arg0) {
|
|
2314
|
-
const ptr0 = passArray8ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
2315
|
-
const len0 = WASM_VECTOR_LEN;
|
|
2316
|
-
wasm.__wbg_set_hmackey_key(this.__wbg_ptr, ptr0, len0);
|
|
2317
|
-
}
|
|
2318
|
-
/**
|
|
2319
|
-
* @returns {bigint}
|
|
2320
|
-
*/
|
|
2321
|
-
get epoch() {
|
|
2322
|
-
const ret = wasm.__wbg_get_hmackey_epoch(this.__wbg_ptr);
|
|
2323
|
-
return ret;
|
|
2324
|
-
}
|
|
2325
|
-
/**
|
|
2326
|
-
* @param {bigint} arg0
|
|
2327
|
-
*/
|
|
2328
|
-
set epoch(arg0) {
|
|
2329
|
-
wasm.__wbg_set_hmackey_epoch(this.__wbg_ptr, arg0);
|
|
2330
|
-
}
|
|
2331
|
-
}
|
|
2332
|
-
|
|
2333
|
-
const InboxStateFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
2334
|
-
? { register: () => {}, unregister: () => {} }
|
|
2335
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_inboxstate_free(ptr >>> 0, 1));
|
|
2336
|
-
|
|
2337
|
-
export class InboxState {
|
|
2338
|
-
|
|
2339
|
-
static __wrap(ptr) {
|
|
2340
|
-
ptr = ptr >>> 0;
|
|
2341
|
-
const obj = Object.create(InboxState.prototype);
|
|
2342
|
-
obj.__wbg_ptr = ptr;
|
|
2343
|
-
InboxStateFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
2344
|
-
return obj;
|
|
2345
|
-
}
|
|
2346
|
-
|
|
2347
|
-
__destroy_into_raw() {
|
|
2348
|
-
const ptr = this.__wbg_ptr;
|
|
2349
|
-
this.__wbg_ptr = 0;
|
|
2350
|
-
InboxStateFinalization.unregister(this);
|
|
2351
|
-
return ptr;
|
|
2352
|
-
}
|
|
2353
|
-
|
|
2354
|
-
free() {
|
|
2355
|
-
const ptr = this.__destroy_into_raw();
|
|
2356
|
-
wasm.__wbg_inboxstate_free(ptr, 0);
|
|
2357
|
-
}
|
|
2358
|
-
/**
|
|
2359
|
-
* @returns {string}
|
|
2360
|
-
*/
|
|
2361
|
-
get inboxId() {
|
|
2362
|
-
let deferred1_0;
|
|
2363
|
-
let deferred1_1;
|
|
2364
|
-
try {
|
|
2365
|
-
const ret = wasm.__wbg_get_inboxstate_inboxId(this.__wbg_ptr);
|
|
2366
|
-
deferred1_0 = ret[0];
|
|
2367
|
-
deferred1_1 = ret[1];
|
|
2368
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
2369
|
-
} finally {
|
|
2370
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
2371
|
-
}
|
|
2372
|
-
}
|
|
2373
|
-
/**
|
|
2374
|
-
* @param {string} arg0
|
|
2375
|
-
*/
|
|
2376
|
-
set inboxId(arg0) {
|
|
2377
|
-
const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
2378
|
-
const len0 = WASM_VECTOR_LEN;
|
|
2379
|
-
wasm.__wbg_set_consent_entity(this.__wbg_ptr, ptr0, len0);
|
|
2380
|
-
}
|
|
2381
|
-
/**
|
|
2382
|
-
* @returns {string}
|
|
2383
|
-
*/
|
|
2384
|
-
get recoveryAddress() {
|
|
2385
|
-
let deferred1_0;
|
|
2386
|
-
let deferred1_1;
|
|
2387
|
-
try {
|
|
2388
|
-
const ret = wasm.__wbg_get_inboxstate_recoveryAddress(this.__wbg_ptr);
|
|
2389
|
-
deferred1_0 = ret[0];
|
|
2390
|
-
deferred1_1 = ret[1];
|
|
2391
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
2392
|
-
} finally {
|
|
2393
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
2394
|
-
}
|
|
2395
|
-
}
|
|
2396
|
-
/**
|
|
2397
|
-
* @param {string} arg0
|
|
2398
|
-
*/
|
|
2399
|
-
set recoveryAddress(arg0) {
|
|
2400
|
-
const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
2401
|
-
const len0 = WASM_VECTOR_LEN;
|
|
2402
|
-
wasm.__wbg_set_contenttypeid_typeId(this.__wbg_ptr, ptr0, len0);
|
|
2403
|
-
}
|
|
2404
|
-
/**
|
|
2405
|
-
* @returns {Installation[]}
|
|
2406
|
-
*/
|
|
2407
|
-
get installations() {
|
|
2408
|
-
const ret = wasm.__wbg_get_inboxstate_installations(this.__wbg_ptr);
|
|
2409
|
-
var v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
|
|
2410
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
2411
|
-
return v1;
|
|
2412
|
-
}
|
|
2413
|
-
/**
|
|
2414
|
-
* @param {Installation[]} arg0
|
|
2415
|
-
*/
|
|
2416
|
-
set installations(arg0) {
|
|
2417
|
-
const ptr0 = passArrayJsValueToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
2418
|
-
const len0 = WASM_VECTOR_LEN;
|
|
2419
|
-
wasm.__wbg_set_inboxstate_installations(this.__wbg_ptr, ptr0, len0);
|
|
2420
|
-
}
|
|
2421
|
-
/**
|
|
2422
|
-
* @returns {string[]}
|
|
2423
|
-
*/
|
|
2424
|
-
get accountAddresses() {
|
|
2425
|
-
const ret = wasm.__wbg_get_inboxstate_accountAddresses(this.__wbg_ptr);
|
|
2426
|
-
var v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
|
|
2427
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
2428
|
-
return v1;
|
|
2429
|
-
}
|
|
2430
|
-
/**
|
|
2431
|
-
* @param {string[]} arg0
|
|
2432
|
-
*/
|
|
2433
|
-
set accountAddresses(arg0) {
|
|
2434
|
-
const ptr0 = passArrayJsValueToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
2435
|
-
const len0 = WASM_VECTOR_LEN;
|
|
2436
|
-
wasm.__wbg_set_inboxstate_accountAddresses(this.__wbg_ptr, ptr0, len0);
|
|
2437
|
-
}
|
|
2438
|
-
/**
|
|
2439
|
-
* @param {string} inbox_id
|
|
2440
|
-
* @param {string} recovery_address
|
|
2441
|
-
* @param {Installation[]} installations
|
|
2442
|
-
* @param {string[]} account_addresses
|
|
2443
|
-
*/
|
|
2444
|
-
constructor(inbox_id, recovery_address, installations, account_addresses) {
|
|
2445
|
-
const ptr0 = passStringToWasm0(inbox_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
2446
|
-
const len0 = WASM_VECTOR_LEN;
|
|
2447
|
-
const ptr1 = passStringToWasm0(recovery_address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
2448
|
-
const len1 = WASM_VECTOR_LEN;
|
|
2449
|
-
const ptr2 = passArrayJsValueToWasm0(installations, wasm.__wbindgen_malloc);
|
|
2450
|
-
const len2 = WASM_VECTOR_LEN;
|
|
2451
|
-
const ptr3 = passArrayJsValueToWasm0(account_addresses, wasm.__wbindgen_malloc);
|
|
2452
|
-
const len3 = WASM_VECTOR_LEN;
|
|
2453
|
-
const ret = wasm.inboxstate_new(ptr0, len0, ptr1, len1, ptr2, len2, ptr3, len3);
|
|
2454
|
-
this.__wbg_ptr = ret >>> 0;
|
|
2455
|
-
InboxStateFinalization.register(this, this.__wbg_ptr, this);
|
|
2456
|
-
return this;
|
|
2457
|
-
}
|
|
2458
|
-
}
|
|
2459
|
-
|
|
2460
|
-
const InstallationFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
2461
|
-
? { register: () => {}, unregister: () => {} }
|
|
2462
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_installation_free(ptr >>> 0, 1));
|
|
2463
|
-
|
|
2464
|
-
export class Installation {
|
|
2465
|
-
|
|
2466
|
-
static __wrap(ptr) {
|
|
2467
|
-
ptr = ptr >>> 0;
|
|
2468
|
-
const obj = Object.create(Installation.prototype);
|
|
2469
|
-
obj.__wbg_ptr = ptr;
|
|
2470
|
-
InstallationFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
2471
|
-
return obj;
|
|
2472
|
-
}
|
|
2473
|
-
|
|
2474
|
-
static __unwrap(jsValue) {
|
|
2475
|
-
if (!(jsValue instanceof Installation)) {
|
|
2476
|
-
return 0;
|
|
2477
|
-
}
|
|
2478
|
-
return jsValue.__destroy_into_raw();
|
|
2479
|
-
}
|
|
2480
|
-
|
|
2481
|
-
__destroy_into_raw() {
|
|
2482
|
-
const ptr = this.__wbg_ptr;
|
|
2483
|
-
this.__wbg_ptr = 0;
|
|
2484
|
-
InstallationFinalization.unregister(this);
|
|
2485
|
-
return ptr;
|
|
2486
|
-
}
|
|
2487
|
-
|
|
2488
|
-
free() {
|
|
2489
|
-
const ptr = this.__destroy_into_raw();
|
|
2490
|
-
wasm.__wbg_installation_free(ptr, 0);
|
|
2491
|
-
}
|
|
2492
|
-
/**
|
|
2493
|
-
* @returns {Uint8Array}
|
|
2494
|
-
*/
|
|
2495
|
-
get bytes() {
|
|
2496
|
-
const ret = wasm.__wbg_get_installation_bytes(this.__wbg_ptr);
|
|
2497
|
-
return ret;
|
|
2498
|
-
}
|
|
2499
|
-
/**
|
|
2500
|
-
* @param {Uint8Array} arg0
|
|
2501
|
-
*/
|
|
2502
|
-
set bytes(arg0) {
|
|
2503
|
-
wasm.__wbg_set_installation_bytes(this.__wbg_ptr, arg0);
|
|
2504
|
-
}
|
|
2505
|
-
/**
|
|
2506
|
-
* @returns {string}
|
|
2507
|
-
*/
|
|
2508
|
-
get id() {
|
|
2509
|
-
let deferred1_0;
|
|
2510
|
-
let deferred1_1;
|
|
2511
|
-
try {
|
|
2512
|
-
const ret = wasm.__wbg_get_installation_id(this.__wbg_ptr);
|
|
2513
|
-
deferred1_0 = ret[0];
|
|
2514
|
-
deferred1_1 = ret[1];
|
|
2515
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
2516
|
-
} finally {
|
|
2517
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
2518
|
-
}
|
|
2519
|
-
}
|
|
2520
|
-
/**
|
|
2521
|
-
* @param {string} arg0
|
|
2522
|
-
*/
|
|
2523
|
-
set id(arg0) {
|
|
2524
|
-
const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
2525
|
-
const len0 = WASM_VECTOR_LEN;
|
|
2526
|
-
wasm.__wbg_set_installation_id(this.__wbg_ptr, ptr0, len0);
|
|
2527
|
-
}
|
|
2528
|
-
/**
|
|
2529
|
-
* @returns {bigint | undefined}
|
|
2530
|
-
*/
|
|
2531
|
-
get clientTimestampNs() {
|
|
2532
|
-
const ret = wasm.__wbg_get_installation_clientTimestampNs(this.__wbg_ptr);
|
|
2533
|
-
return ret[0] === 0 ? undefined : BigInt.asUintN(64, ret[1]);
|
|
2534
|
-
}
|
|
2535
|
-
/**
|
|
2536
|
-
* @param {bigint | null} [arg0]
|
|
2537
|
-
*/
|
|
2538
|
-
set clientTimestampNs(arg0) {
|
|
2539
|
-
wasm.__wbg_set_installation_clientTimestampNs(this.__wbg_ptr, !isLikeNone(arg0), isLikeNone(arg0) ? BigInt(0) : arg0);
|
|
2540
|
-
}
|
|
2541
|
-
/**
|
|
2542
|
-
* @param {Uint8Array} bytes
|
|
2543
|
-
* @param {string} id
|
|
2544
|
-
* @param {bigint | null} [client_timestamp_ns]
|
|
2545
|
-
*/
|
|
2546
|
-
constructor(bytes, id, client_timestamp_ns) {
|
|
2547
|
-
const ptr0 = passStringToWasm0(id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
2548
|
-
const len0 = WASM_VECTOR_LEN;
|
|
2549
|
-
const ret = wasm.installation_new(bytes, ptr0, len0, !isLikeNone(client_timestamp_ns), isLikeNone(client_timestamp_ns) ? BigInt(0) : client_timestamp_ns);
|
|
2550
|
-
this.__wbg_ptr = ret >>> 0;
|
|
2551
|
-
InstallationFinalization.register(this, this.__wbg_ptr, this);
|
|
2552
|
-
return this;
|
|
2553
|
-
}
|
|
2554
|
-
}
|
|
2555
|
-
|
|
2556
|
-
const IntoUnderlyingByteSourceFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
2557
|
-
? { register: () => {}, unregister: () => {} }
|
|
2558
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_intounderlyingbytesource_free(ptr >>> 0, 1));
|
|
2559
|
-
|
|
2560
|
-
export class IntoUnderlyingByteSource {
|
|
2561
|
-
|
|
2562
|
-
__destroy_into_raw() {
|
|
2563
|
-
const ptr = this.__wbg_ptr;
|
|
2564
|
-
this.__wbg_ptr = 0;
|
|
2565
|
-
IntoUnderlyingByteSourceFinalization.unregister(this);
|
|
2566
|
-
return ptr;
|
|
2567
|
-
}
|
|
2568
|
-
|
|
2569
|
-
free() {
|
|
2570
|
-
const ptr = this.__destroy_into_raw();
|
|
2571
|
-
wasm.__wbg_intounderlyingbytesource_free(ptr, 0);
|
|
2572
|
-
}
|
|
2573
|
-
/**
|
|
2574
|
-
* @returns {ReadableStreamType}
|
|
2575
|
-
*/
|
|
2576
|
-
get type() {
|
|
2577
|
-
const ret = wasm.intounderlyingbytesource_type(this.__wbg_ptr);
|
|
2578
|
-
return __wbindgen_enum_ReadableStreamType[ret];
|
|
2579
|
-
}
|
|
2580
|
-
/**
|
|
2581
|
-
* @returns {number}
|
|
2582
|
-
*/
|
|
2583
|
-
get autoAllocateChunkSize() {
|
|
2584
|
-
const ret = wasm.intounderlyingbytesource_autoAllocateChunkSize(this.__wbg_ptr);
|
|
2585
|
-
return ret >>> 0;
|
|
2586
|
-
}
|
|
2587
|
-
/**
|
|
2588
|
-
* @param {ReadableByteStreamController} controller
|
|
2589
|
-
*/
|
|
2590
|
-
start(controller) {
|
|
2591
|
-
wasm.intounderlyingbytesource_start(this.__wbg_ptr, controller);
|
|
2592
|
-
}
|
|
2593
|
-
/**
|
|
2594
|
-
* @param {ReadableByteStreamController} controller
|
|
2595
|
-
* @returns {Promise<any>}
|
|
2596
|
-
*/
|
|
2597
|
-
pull(controller) {
|
|
2598
|
-
const ret = wasm.intounderlyingbytesource_pull(this.__wbg_ptr, controller);
|
|
2599
|
-
return ret;
|
|
2600
|
-
}
|
|
2601
|
-
cancel() {
|
|
2602
|
-
const ptr = this.__destroy_into_raw();
|
|
2603
|
-
wasm.intounderlyingbytesource_cancel(ptr);
|
|
2604
|
-
}
|
|
2605
|
-
}
|
|
2606
|
-
|
|
2607
|
-
const IntoUnderlyingSinkFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
2608
|
-
? { register: () => {}, unregister: () => {} }
|
|
2609
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_intounderlyingsink_free(ptr >>> 0, 1));
|
|
2610
|
-
|
|
2611
|
-
export class IntoUnderlyingSink {
|
|
2612
|
-
|
|
2613
|
-
__destroy_into_raw() {
|
|
2614
|
-
const ptr = this.__wbg_ptr;
|
|
2615
|
-
this.__wbg_ptr = 0;
|
|
2616
|
-
IntoUnderlyingSinkFinalization.unregister(this);
|
|
2617
|
-
return ptr;
|
|
2618
|
-
}
|
|
2619
|
-
|
|
2620
|
-
free() {
|
|
2621
|
-
const ptr = this.__destroy_into_raw();
|
|
2622
|
-
wasm.__wbg_intounderlyingsink_free(ptr, 0);
|
|
2623
|
-
}
|
|
2624
|
-
/**
|
|
2625
|
-
* @param {any} chunk
|
|
2626
|
-
* @returns {Promise<any>}
|
|
2627
|
-
*/
|
|
2628
|
-
write(chunk) {
|
|
2629
|
-
const ret = wasm.intounderlyingsink_write(this.__wbg_ptr, chunk);
|
|
2630
|
-
return ret;
|
|
2631
|
-
}
|
|
2632
|
-
/**
|
|
2633
|
-
* @returns {Promise<any>}
|
|
2634
|
-
*/
|
|
2635
|
-
close() {
|
|
2636
|
-
const ptr = this.__destroy_into_raw();
|
|
2637
|
-
const ret = wasm.intounderlyingsink_close(ptr);
|
|
2638
|
-
return ret;
|
|
2639
|
-
}
|
|
2640
|
-
/**
|
|
2641
|
-
* @param {any} reason
|
|
2642
|
-
* @returns {Promise<any>}
|
|
2643
|
-
*/
|
|
2644
|
-
abort(reason) {
|
|
2645
|
-
const ptr = this.__destroy_into_raw();
|
|
2646
|
-
const ret = wasm.intounderlyingsink_abort(ptr, reason);
|
|
2647
|
-
return ret;
|
|
2648
|
-
}
|
|
2649
|
-
}
|
|
2650
|
-
|
|
2651
|
-
const IntoUnderlyingSourceFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
2652
|
-
? { register: () => {}, unregister: () => {} }
|
|
2653
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_intounderlyingsource_free(ptr >>> 0, 1));
|
|
2654
|
-
|
|
2655
|
-
export class IntoUnderlyingSource {
|
|
2656
|
-
|
|
2657
|
-
__destroy_into_raw() {
|
|
2658
|
-
const ptr = this.__wbg_ptr;
|
|
2659
|
-
this.__wbg_ptr = 0;
|
|
2660
|
-
IntoUnderlyingSourceFinalization.unregister(this);
|
|
2661
|
-
return ptr;
|
|
2662
|
-
}
|
|
2663
|
-
|
|
2664
|
-
free() {
|
|
2665
|
-
const ptr = this.__destroy_into_raw();
|
|
2666
|
-
wasm.__wbg_intounderlyingsource_free(ptr, 0);
|
|
2667
|
-
}
|
|
2668
|
-
/**
|
|
2669
|
-
* @param {ReadableStreamDefaultController} controller
|
|
2670
|
-
* @returns {Promise<any>}
|
|
2671
|
-
*/
|
|
2672
|
-
pull(controller) {
|
|
2673
|
-
const ret = wasm.intounderlyingsource_pull(this.__wbg_ptr, controller);
|
|
2674
|
-
return ret;
|
|
2675
|
-
}
|
|
2676
|
-
cancel() {
|
|
2677
|
-
const ptr = this.__destroy_into_raw();
|
|
2678
|
-
wasm.intounderlyingsource_cancel(ptr);
|
|
2679
|
-
}
|
|
2680
|
-
}
|
|
2681
|
-
|
|
2682
|
-
const ListConversationsOptionsFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
2683
|
-
? { register: () => {}, unregister: () => {} }
|
|
2684
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_listconversationsoptions_free(ptr >>> 0, 1));
|
|
2685
|
-
|
|
2686
|
-
export class ListConversationsOptions {
|
|
2687
|
-
|
|
2688
|
-
__destroy_into_raw() {
|
|
2689
|
-
const ptr = this.__wbg_ptr;
|
|
2690
|
-
this.__wbg_ptr = 0;
|
|
2691
|
-
ListConversationsOptionsFinalization.unregister(this);
|
|
2692
|
-
return ptr;
|
|
2693
|
-
}
|
|
2694
|
-
|
|
2695
|
-
free() {
|
|
2696
|
-
const ptr = this.__destroy_into_raw();
|
|
2697
|
-
wasm.__wbg_listconversationsoptions_free(ptr, 0);
|
|
2698
|
-
}
|
|
2699
|
-
/**
|
|
2700
|
-
* @returns {any[] | undefined}
|
|
2701
|
-
*/
|
|
2702
|
-
get allowedStates() {
|
|
2703
|
-
const ret = wasm.__wbg_get_listconversationsoptions_allowedStates(this.__wbg_ptr);
|
|
2704
|
-
let v1;
|
|
2705
|
-
if (ret[0] !== 0) {
|
|
2706
|
-
v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
|
|
2707
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
2708
|
-
}
|
|
2709
|
-
return v1;
|
|
2710
|
-
}
|
|
2711
|
-
/**
|
|
2712
|
-
* @param {any[] | null} [arg0]
|
|
2713
|
-
*/
|
|
2714
|
-
set allowedStates(arg0) {
|
|
2715
|
-
var ptr0 = isLikeNone(arg0) ? 0 : passArrayJsValueToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
2716
|
-
var len0 = WASM_VECTOR_LEN;
|
|
2717
|
-
wasm.__wbg_set_listconversationsoptions_allowedStates(this.__wbg_ptr, ptr0, len0);
|
|
2718
|
-
}
|
|
2719
|
-
/**
|
|
2720
|
-
* @returns {any[] | undefined}
|
|
2721
|
-
*/
|
|
2722
|
-
get consentStates() {
|
|
2723
|
-
const ret = wasm.__wbg_get_listconversationsoptions_consentStates(this.__wbg_ptr);
|
|
2724
|
-
let v1;
|
|
2725
|
-
if (ret[0] !== 0) {
|
|
2726
|
-
v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
|
|
2727
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
2728
|
-
}
|
|
2729
|
-
return v1;
|
|
2730
|
-
}
|
|
2731
|
-
/**
|
|
2732
|
-
* @param {any[] | null} [arg0]
|
|
2733
|
-
*/
|
|
2734
|
-
set consentStates(arg0) {
|
|
2735
|
-
var ptr0 = isLikeNone(arg0) ? 0 : passArrayJsValueToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
2736
|
-
var len0 = WASM_VECTOR_LEN;
|
|
2737
|
-
wasm.__wbg_set_listconversationsoptions_consentStates(this.__wbg_ptr, ptr0, len0);
|
|
2738
|
-
}
|
|
2739
|
-
/**
|
|
2740
|
-
* @returns {ConversationType | undefined}
|
|
2741
|
-
*/
|
|
2742
|
-
get conversationType() {
|
|
2743
|
-
const ret = wasm.__wbg_get_listconversationsoptions_conversationType(this.__wbg_ptr);
|
|
2744
|
-
return ret === 3 ? undefined : ret;
|
|
2745
|
-
}
|
|
2746
|
-
/**
|
|
2747
|
-
* @param {ConversationType | null} [arg0]
|
|
2748
|
-
*/
|
|
2749
|
-
set conversationType(arg0) {
|
|
2750
|
-
wasm.__wbg_set_listconversationsoptions_conversationType(this.__wbg_ptr, isLikeNone(arg0) ? 3 : arg0);
|
|
2751
|
-
}
|
|
2752
|
-
/**
|
|
2753
|
-
* @returns {bigint | undefined}
|
|
2754
|
-
*/
|
|
2755
|
-
get createdAfterNs() {
|
|
2756
|
-
const ret = wasm.__wbg_get_listconversationsoptions_createdAfterNs(this.__wbg_ptr);
|
|
2757
|
-
return ret[0] === 0 ? undefined : ret[1];
|
|
2758
|
-
}
|
|
2759
|
-
/**
|
|
2760
|
-
* @param {bigint | null} [arg0]
|
|
2761
|
-
*/
|
|
2762
|
-
set createdAfterNs(arg0) {
|
|
2763
|
-
wasm.__wbg_set_listconversationsoptions_createdAfterNs(this.__wbg_ptr, !isLikeNone(arg0), isLikeNone(arg0) ? BigInt(0) : arg0);
|
|
2764
|
-
}
|
|
2765
|
-
/**
|
|
2766
|
-
* @returns {bigint | undefined}
|
|
2767
|
-
*/
|
|
2768
|
-
get createdBeforeNs() {
|
|
2769
|
-
const ret = wasm.__wbg_get_listconversationsoptions_createdBeforeNs(this.__wbg_ptr);
|
|
2770
|
-
return ret[0] === 0 ? undefined : ret[1];
|
|
2771
|
-
}
|
|
2772
|
-
/**
|
|
2773
|
-
* @param {bigint | null} [arg0]
|
|
2774
|
-
*/
|
|
2775
|
-
set createdBeforeNs(arg0) {
|
|
2776
|
-
wasm.__wbg_set_listconversationsoptions_createdBeforeNs(this.__wbg_ptr, !isLikeNone(arg0), isLikeNone(arg0) ? BigInt(0) : arg0);
|
|
2777
|
-
}
|
|
2778
|
-
/**
|
|
2779
|
-
* @returns {boolean}
|
|
2780
|
-
*/
|
|
2781
|
-
get includeDuplicateDms() {
|
|
2782
|
-
const ret = wasm.__wbg_get_listconversationsoptions_includeDuplicateDms(this.__wbg_ptr);
|
|
2783
|
-
return ret !== 0;
|
|
2784
|
-
}
|
|
2785
|
-
/**
|
|
2786
|
-
* @param {boolean} arg0
|
|
2787
|
-
*/
|
|
2788
|
-
set includeDuplicateDms(arg0) {
|
|
2789
|
-
wasm.__wbg_set_listconversationsoptions_includeDuplicateDms(this.__wbg_ptr, arg0);
|
|
2790
|
-
}
|
|
2791
|
-
/**
|
|
2792
|
-
* @returns {boolean}
|
|
2793
|
-
*/
|
|
2794
|
-
get includeSyncGroups() {
|
|
2795
|
-
const ret = wasm.__wbg_get_listconversationsoptions_includeSyncGroups(this.__wbg_ptr);
|
|
2796
|
-
return ret !== 0;
|
|
2797
|
-
}
|
|
2798
|
-
/**
|
|
2799
|
-
* @param {boolean} arg0
|
|
2800
|
-
*/
|
|
2801
|
-
set includeSyncGroups(arg0) {
|
|
2802
|
-
wasm.__wbg_set_listconversationsoptions_includeSyncGroups(this.__wbg_ptr, arg0);
|
|
2803
|
-
}
|
|
2804
|
-
/**
|
|
2805
|
-
* @returns {bigint | undefined}
|
|
2806
|
-
*/
|
|
2807
|
-
get limit() {
|
|
2808
|
-
const ret = wasm.__wbg_get_listconversationsoptions_limit(this.__wbg_ptr);
|
|
2809
|
-
return ret[0] === 0 ? undefined : ret[1];
|
|
2810
|
-
}
|
|
2811
|
-
/**
|
|
2812
|
-
* @param {bigint | null} [arg0]
|
|
2813
|
-
*/
|
|
2814
|
-
set limit(arg0) {
|
|
2815
|
-
wasm.__wbg_set_listconversationsoptions_limit(this.__wbg_ptr, !isLikeNone(arg0), isLikeNone(arg0) ? BigInt(0) : arg0);
|
|
2816
|
-
}
|
|
2817
|
-
/**
|
|
2818
|
-
* @param {any[] | null | undefined} allowed_states
|
|
2819
|
-
* @param {any[] | null | undefined} consent_states
|
|
2820
|
-
* @param {ConversationType | null | undefined} conversation_type
|
|
2821
|
-
* @param {bigint | null | undefined} created_after_ns
|
|
2822
|
-
* @param {bigint | null | undefined} created_before_ns
|
|
2823
|
-
* @param {boolean} include_duplicate_dms
|
|
2824
|
-
* @param {boolean} include_sync_groups
|
|
2825
|
-
* @param {bigint | null} [limit]
|
|
2826
|
-
*/
|
|
2827
|
-
constructor(allowed_states, consent_states, conversation_type, created_after_ns, created_before_ns, include_duplicate_dms, include_sync_groups, limit) {
|
|
2828
|
-
var ptr0 = isLikeNone(allowed_states) ? 0 : passArrayJsValueToWasm0(allowed_states, wasm.__wbindgen_malloc);
|
|
2829
|
-
var len0 = WASM_VECTOR_LEN;
|
|
2830
|
-
var ptr1 = isLikeNone(consent_states) ? 0 : passArrayJsValueToWasm0(consent_states, wasm.__wbindgen_malloc);
|
|
2831
|
-
var len1 = WASM_VECTOR_LEN;
|
|
2832
|
-
const ret = wasm.listconversationsoptions_new(ptr0, len0, ptr1, len1, isLikeNone(conversation_type) ? 3 : conversation_type, !isLikeNone(created_after_ns), isLikeNone(created_after_ns) ? BigInt(0) : created_after_ns, !isLikeNone(created_before_ns), isLikeNone(created_before_ns) ? BigInt(0) : created_before_ns, include_duplicate_dms, include_sync_groups, !isLikeNone(limit), isLikeNone(limit) ? BigInt(0) : limit);
|
|
2833
|
-
this.__wbg_ptr = ret >>> 0;
|
|
2834
|
-
ListConversationsOptionsFinalization.register(this, this.__wbg_ptr, this);
|
|
2835
|
-
return this;
|
|
2836
|
-
}
|
|
2837
|
-
}
|
|
2838
|
-
|
|
2839
|
-
const ListMessagesOptionsFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
2840
|
-
? { register: () => {}, unregister: () => {} }
|
|
2841
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_listmessagesoptions_free(ptr >>> 0, 1));
|
|
2842
|
-
|
|
2843
|
-
export class ListMessagesOptions {
|
|
2844
|
-
|
|
2845
|
-
__destroy_into_raw() {
|
|
2846
|
-
const ptr = this.__wbg_ptr;
|
|
2847
|
-
this.__wbg_ptr = 0;
|
|
2848
|
-
ListMessagesOptionsFinalization.unregister(this);
|
|
2849
|
-
return ptr;
|
|
2850
|
-
}
|
|
2851
|
-
|
|
2852
|
-
free() {
|
|
2853
|
-
const ptr = this.__destroy_into_raw();
|
|
2854
|
-
wasm.__wbg_listmessagesoptions_free(ptr, 0);
|
|
2855
|
-
}
|
|
2856
|
-
/**
|
|
2857
|
-
* @returns {bigint | undefined}
|
|
2858
|
-
*/
|
|
2859
|
-
get sentBeforeNs() {
|
|
2860
|
-
const ret = wasm.__wbg_get_listmessagesoptions_sentBeforeNs(this.__wbg_ptr);
|
|
2861
|
-
return ret[0] === 0 ? undefined : ret[1];
|
|
2862
|
-
}
|
|
2863
|
-
/**
|
|
2864
|
-
* @param {bigint | null} [arg0]
|
|
2865
|
-
*/
|
|
2866
|
-
set sentBeforeNs(arg0) {
|
|
2867
|
-
wasm.__wbg_set_listconversationsoptions_createdAfterNs(this.__wbg_ptr, !isLikeNone(arg0), isLikeNone(arg0) ? BigInt(0) : arg0);
|
|
2868
|
-
}
|
|
2869
|
-
/**
|
|
2870
|
-
* @returns {bigint | undefined}
|
|
2871
|
-
*/
|
|
2872
|
-
get sentAfterNs() {
|
|
2873
|
-
const ret = wasm.__wbg_get_listmessagesoptions_sentAfterNs(this.__wbg_ptr);
|
|
2874
|
-
return ret[0] === 0 ? undefined : ret[1];
|
|
2875
|
-
}
|
|
2876
|
-
/**
|
|
2877
|
-
* @param {bigint | null} [arg0]
|
|
2878
|
-
*/
|
|
2879
|
-
set sentAfterNs(arg0) {
|
|
2880
|
-
wasm.__wbg_set_listconversationsoptions_createdBeforeNs(this.__wbg_ptr, !isLikeNone(arg0), isLikeNone(arg0) ? BigInt(0) : arg0);
|
|
2881
|
-
}
|
|
2882
|
-
/**
|
|
2883
|
-
* @returns {bigint | undefined}
|
|
2884
|
-
*/
|
|
2885
|
-
get limit() {
|
|
2886
|
-
const ret = wasm.__wbg_get_listmessagesoptions_limit(this.__wbg_ptr);
|
|
2887
|
-
return ret[0] === 0 ? undefined : ret[1];
|
|
2888
|
-
}
|
|
2889
|
-
/**
|
|
2890
|
-
* @param {bigint | null} [arg0]
|
|
2891
|
-
*/
|
|
2892
|
-
set limit(arg0) {
|
|
2893
|
-
wasm.__wbg_set_listconversationsoptions_limit(this.__wbg_ptr, !isLikeNone(arg0), isLikeNone(arg0) ? BigInt(0) : arg0);
|
|
2894
|
-
}
|
|
2895
|
-
/**
|
|
2896
|
-
* @returns {DeliveryStatus | undefined}
|
|
2897
|
-
*/
|
|
2898
|
-
get deliveryStatus() {
|
|
2899
|
-
const ret = wasm.__wbg_get_listmessagesoptions_deliveryStatus(this.__wbg_ptr);
|
|
2900
|
-
return ret === 3 ? undefined : ret;
|
|
2901
|
-
}
|
|
2902
|
-
/**
|
|
2903
|
-
* @param {DeliveryStatus | null} [arg0]
|
|
2904
|
-
*/
|
|
2905
|
-
set deliveryStatus(arg0) {
|
|
2906
|
-
wasm.__wbg_set_listmessagesoptions_deliveryStatus(this.__wbg_ptr, isLikeNone(arg0) ? 3 : arg0);
|
|
2907
|
-
}
|
|
2908
|
-
/**
|
|
2909
|
-
* @returns {SortDirection | undefined}
|
|
2910
|
-
*/
|
|
2911
|
-
get direction() {
|
|
2912
|
-
const ret = wasm.__wbg_get_listmessagesoptions_direction(this.__wbg_ptr);
|
|
2913
|
-
return ret === 2 ? undefined : ret;
|
|
2914
|
-
}
|
|
2915
|
-
/**
|
|
2916
|
-
* @param {SortDirection | null} [arg0]
|
|
2917
|
-
*/
|
|
2918
|
-
set direction(arg0) {
|
|
2919
|
-
wasm.__wbg_set_listmessagesoptions_direction(this.__wbg_ptr, isLikeNone(arg0) ? 2 : arg0);
|
|
2920
|
-
}
|
|
2921
|
-
/**
|
|
2922
|
-
* @param {bigint | null} [sent_before_ns]
|
|
2923
|
-
* @param {bigint | null} [sent_after_ns]
|
|
2924
|
-
* @param {bigint | null} [limit]
|
|
2925
|
-
* @param {DeliveryStatus | null} [delivery_status]
|
|
2926
|
-
* @param {SortDirection | null} [direction]
|
|
2927
|
-
*/
|
|
2928
|
-
constructor(sent_before_ns, sent_after_ns, limit, delivery_status, direction) {
|
|
2929
|
-
const ret = wasm.listmessagesoptions_new(!isLikeNone(sent_before_ns), isLikeNone(sent_before_ns) ? BigInt(0) : sent_before_ns, !isLikeNone(sent_after_ns), isLikeNone(sent_after_ns) ? BigInt(0) : sent_after_ns, !isLikeNone(limit), isLikeNone(limit) ? BigInt(0) : limit, isLikeNone(delivery_status) ? 3 : delivery_status, isLikeNone(direction) ? 2 : direction);
|
|
2930
|
-
this.__wbg_ptr = ret >>> 0;
|
|
2931
|
-
ListMessagesOptionsFinalization.register(this, this.__wbg_ptr, this);
|
|
2932
|
-
return this;
|
|
2933
|
-
}
|
|
2934
|
-
}
|
|
2935
|
-
|
|
2936
|
-
const LogOptionsFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
2937
|
-
? { register: () => {}, unregister: () => {} }
|
|
2938
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_logoptions_free(ptr >>> 0, 1));
|
|
2939
|
-
/**
|
|
2940
|
-
* Specify options for the logger
|
|
2941
|
-
*/
|
|
2942
|
-
export class LogOptions {
|
|
2943
|
-
|
|
2944
|
-
__destroy_into_raw() {
|
|
2945
|
-
const ptr = this.__wbg_ptr;
|
|
2946
|
-
this.__wbg_ptr = 0;
|
|
2947
|
-
LogOptionsFinalization.unregister(this);
|
|
2948
|
-
return ptr;
|
|
2949
|
-
}
|
|
2950
|
-
|
|
2951
|
-
free() {
|
|
2952
|
-
const ptr = this.__destroy_into_raw();
|
|
2953
|
-
wasm.__wbg_logoptions_free(ptr, 0);
|
|
2954
|
-
}
|
|
2955
|
-
/**
|
|
2956
|
-
* enable structured JSON logging to stdout.Useful for third-party log viewers
|
|
2957
|
-
* @returns {boolean}
|
|
2958
|
-
*/
|
|
2959
|
-
get structured() {
|
|
2960
|
-
const ret = wasm.__wbg_get_logoptions_structured(this.__wbg_ptr);
|
|
2961
|
-
return ret !== 0;
|
|
2962
|
-
}
|
|
2963
|
-
/**
|
|
2964
|
-
* enable structured JSON logging to stdout.Useful for third-party log viewers
|
|
2965
|
-
* @param {boolean} arg0
|
|
2966
|
-
*/
|
|
2967
|
-
set structured(arg0) {
|
|
2968
|
-
wasm.__wbg_set_logoptions_structured(this.__wbg_ptr, arg0);
|
|
2969
|
-
}
|
|
2970
|
-
/**
|
|
2971
|
-
* enable performance metrics for libxmtp in the `performance` tab
|
|
2972
|
-
* @returns {boolean}
|
|
2973
|
-
*/
|
|
2974
|
-
get performance() {
|
|
2975
|
-
const ret = wasm.__wbg_get_logoptions_performance(this.__wbg_ptr);
|
|
2976
|
-
return ret !== 0;
|
|
2977
|
-
}
|
|
2978
|
-
/**
|
|
2979
|
-
* enable performance metrics for libxmtp in the `performance` tab
|
|
2980
|
-
* @param {boolean} arg0
|
|
2981
|
-
*/
|
|
2982
|
-
set performance(arg0) {
|
|
2983
|
-
wasm.__wbg_set_logoptions_performance(this.__wbg_ptr, arg0);
|
|
2984
|
-
}
|
|
2985
|
-
/**
|
|
2986
|
-
* filter for logs
|
|
2987
|
-
* @returns {LogLevel | undefined}
|
|
2988
|
-
*/
|
|
2989
|
-
get level() {
|
|
2990
|
-
const ret = wasm.__wbg_get_logoptions_level(this.__wbg_ptr);
|
|
2991
|
-
return __wbindgen_enum_LogLevel[ret];
|
|
2992
|
-
}
|
|
2993
|
-
/**
|
|
2994
|
-
* filter for logs
|
|
2995
|
-
* @param {LogLevel | null} [arg0]
|
|
2996
|
-
*/
|
|
2997
|
-
set level(arg0) {
|
|
2998
|
-
wasm.__wbg_set_logoptions_level(this.__wbg_ptr, isLikeNone(arg0) ? 7 : ((__wbindgen_enum_LogLevel.indexOf(arg0) + 1 || 7) - 1));
|
|
2999
|
-
}
|
|
3000
|
-
/**
|
|
3001
|
-
* @param {boolean} structured
|
|
3002
|
-
* @param {boolean} performance
|
|
3003
|
-
* @param {LogLevel | null} [level]
|
|
3004
|
-
*/
|
|
3005
|
-
constructor(structured, performance, level) {
|
|
3006
|
-
const ret = wasm.logoptions_new(structured, performance, isLikeNone(level) ? 7 : ((__wbindgen_enum_LogLevel.indexOf(level) + 1 || 7) - 1));
|
|
3007
|
-
this.__wbg_ptr = ret >>> 0;
|
|
3008
|
-
LogOptionsFinalization.register(this, this.__wbg_ptr, this);
|
|
3009
|
-
return this;
|
|
3010
|
-
}
|
|
3011
|
-
}
|
|
3012
|
-
|
|
3013
|
-
const MessageFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
3014
|
-
? { register: () => {}, unregister: () => {} }
|
|
3015
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_message_free(ptr >>> 0, 1));
|
|
3016
|
-
|
|
3017
|
-
export class Message {
|
|
3018
|
-
|
|
3019
|
-
static __wrap(ptr) {
|
|
3020
|
-
ptr = ptr >>> 0;
|
|
3021
|
-
const obj = Object.create(Message.prototype);
|
|
3022
|
-
obj.__wbg_ptr = ptr;
|
|
3023
|
-
MessageFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
3024
|
-
return obj;
|
|
3025
|
-
}
|
|
3026
|
-
|
|
3027
|
-
__destroy_into_raw() {
|
|
3028
|
-
const ptr = this.__wbg_ptr;
|
|
3029
|
-
this.__wbg_ptr = 0;
|
|
3030
|
-
MessageFinalization.unregister(this);
|
|
3031
|
-
return ptr;
|
|
3032
|
-
}
|
|
3033
|
-
|
|
3034
|
-
free() {
|
|
3035
|
-
const ptr = this.__destroy_into_raw();
|
|
3036
|
-
wasm.__wbg_message_free(ptr, 0);
|
|
3037
|
-
}
|
|
3038
|
-
/**
|
|
3039
|
-
* @returns {string}
|
|
3040
|
-
*/
|
|
3041
|
-
get id() {
|
|
3042
|
-
let deferred1_0;
|
|
3043
|
-
let deferred1_1;
|
|
3044
|
-
try {
|
|
3045
|
-
const ret = wasm.__wbg_get_message_id(this.__wbg_ptr);
|
|
3046
|
-
deferred1_0 = ret[0];
|
|
3047
|
-
deferred1_1 = ret[1];
|
|
3048
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
3049
|
-
} finally {
|
|
3050
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
3051
|
-
}
|
|
3052
|
-
}
|
|
3053
|
-
/**
|
|
3054
|
-
* @param {string} arg0
|
|
3055
|
-
*/
|
|
3056
|
-
set id(arg0) {
|
|
3057
|
-
const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
3058
|
-
const len0 = WASM_VECTOR_LEN;
|
|
3059
|
-
wasm.__wbg_set_message_id(this.__wbg_ptr, ptr0, len0);
|
|
3060
|
-
}
|
|
3061
|
-
/**
|
|
3062
|
-
* @returns {bigint}
|
|
3063
|
-
*/
|
|
3064
|
-
get sentAtNs() {
|
|
3065
|
-
const ret = wasm.__wbg_get_hmackey_epoch(this.__wbg_ptr);
|
|
3066
|
-
return ret;
|
|
3067
|
-
}
|
|
3068
|
-
/**
|
|
3069
|
-
* @param {bigint} arg0
|
|
3070
|
-
*/
|
|
3071
|
-
set sentAtNs(arg0) {
|
|
3072
|
-
wasm.__wbg_set_hmackey_epoch(this.__wbg_ptr, arg0);
|
|
3073
|
-
}
|
|
3074
|
-
/**
|
|
3075
|
-
* @returns {string}
|
|
3076
|
-
*/
|
|
3077
|
-
get convoId() {
|
|
3078
|
-
let deferred1_0;
|
|
3079
|
-
let deferred1_1;
|
|
3080
|
-
try {
|
|
3081
|
-
const ret = wasm.__wbg_get_message_convoId(this.__wbg_ptr);
|
|
3082
|
-
deferred1_0 = ret[0];
|
|
3083
|
-
deferred1_1 = ret[1];
|
|
3084
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
3085
|
-
} finally {
|
|
3086
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
3087
|
-
}
|
|
3088
|
-
}
|
|
3089
|
-
/**
|
|
3090
|
-
* @param {string} arg0
|
|
3091
|
-
*/
|
|
3092
|
-
set convoId(arg0) {
|
|
3093
|
-
const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
3094
|
-
const len0 = WASM_VECTOR_LEN;
|
|
3095
|
-
wasm.__wbg_set_message_convoId(this.__wbg_ptr, ptr0, len0);
|
|
3096
|
-
}
|
|
3097
|
-
/**
|
|
3098
|
-
* @returns {string}
|
|
3099
|
-
*/
|
|
3100
|
-
get senderInboxId() {
|
|
3101
|
-
let deferred1_0;
|
|
3102
|
-
let deferred1_1;
|
|
3103
|
-
try {
|
|
3104
|
-
const ret = wasm.__wbg_get_message_senderInboxId(this.__wbg_ptr);
|
|
3105
|
-
deferred1_0 = ret[0];
|
|
3106
|
-
deferred1_1 = ret[1];
|
|
3107
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
3108
|
-
} finally {
|
|
3109
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
3110
|
-
}
|
|
3111
|
-
}
|
|
3112
|
-
/**
|
|
3113
|
-
* @param {string} arg0
|
|
3114
|
-
*/
|
|
3115
|
-
set senderInboxId(arg0) {
|
|
3116
|
-
const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
3117
|
-
const len0 = WASM_VECTOR_LEN;
|
|
3118
|
-
wasm.__wbg_set_message_senderInboxId(this.__wbg_ptr, ptr0, len0);
|
|
3119
|
-
}
|
|
3120
|
-
/**
|
|
3121
|
-
* @returns {EncodedContent}
|
|
3122
|
-
*/
|
|
3123
|
-
get content() {
|
|
3124
|
-
const ret = wasm.__wbg_get_message_content(this.__wbg_ptr);
|
|
3125
|
-
return EncodedContent.__wrap(ret);
|
|
3126
|
-
}
|
|
3127
|
-
/**
|
|
3128
|
-
* @param {EncodedContent} arg0
|
|
3129
|
-
*/
|
|
3130
|
-
set content(arg0) {
|
|
3131
|
-
_assertClass(arg0, EncodedContent);
|
|
3132
|
-
var ptr0 = arg0.__destroy_into_raw();
|
|
3133
|
-
wasm.__wbg_set_message_content(this.__wbg_ptr, ptr0);
|
|
3134
|
-
}
|
|
3135
|
-
/**
|
|
3136
|
-
* @returns {GroupMessageKind}
|
|
3137
|
-
*/
|
|
3138
|
-
get kind() {
|
|
3139
|
-
const ret = wasm.__wbg_get_message_kind(this.__wbg_ptr);
|
|
3140
|
-
return ret;
|
|
3141
|
-
}
|
|
3142
|
-
/**
|
|
3143
|
-
* @param {GroupMessageKind} arg0
|
|
3144
|
-
*/
|
|
3145
|
-
set kind(arg0) {
|
|
3146
|
-
wasm.__wbg_set_message_kind(this.__wbg_ptr, arg0);
|
|
3147
|
-
}
|
|
3148
|
-
/**
|
|
3149
|
-
* @returns {DeliveryStatus}
|
|
3150
|
-
*/
|
|
3151
|
-
get deliveryStatus() {
|
|
3152
|
-
const ret = wasm.__wbg_get_message_deliveryStatus(this.__wbg_ptr);
|
|
3153
|
-
return ret;
|
|
3154
|
-
}
|
|
3155
|
-
/**
|
|
3156
|
-
* @param {DeliveryStatus} arg0
|
|
3157
|
-
*/
|
|
3158
|
-
set deliveryStatus(arg0) {
|
|
3159
|
-
wasm.__wbg_set_message_deliveryStatus(this.__wbg_ptr, arg0);
|
|
3160
|
-
}
|
|
3161
|
-
/**
|
|
3162
|
-
* @param {string} id
|
|
3163
|
-
* @param {bigint} sent_at_ns
|
|
3164
|
-
* @param {string} convo_id
|
|
3165
|
-
* @param {string} sender_inbox_id
|
|
3166
|
-
* @param {EncodedContent} content
|
|
3167
|
-
* @param {GroupMessageKind} kind
|
|
3168
|
-
* @param {DeliveryStatus} delivery_status
|
|
3169
|
-
*/
|
|
3170
|
-
constructor(id, sent_at_ns, convo_id, sender_inbox_id, content, kind, delivery_status) {
|
|
3171
|
-
const ptr0 = passStringToWasm0(id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
3172
|
-
const len0 = WASM_VECTOR_LEN;
|
|
3173
|
-
const ptr1 = passStringToWasm0(convo_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
3174
|
-
const len1 = WASM_VECTOR_LEN;
|
|
3175
|
-
const ptr2 = passStringToWasm0(sender_inbox_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
3176
|
-
const len2 = WASM_VECTOR_LEN;
|
|
3177
|
-
_assertClass(content, EncodedContent);
|
|
3178
|
-
var ptr3 = content.__destroy_into_raw();
|
|
3179
|
-
const ret = wasm.message_new(ptr0, len0, sent_at_ns, ptr1, len1, ptr2, len2, ptr3, kind, delivery_status);
|
|
3180
|
-
this.__wbg_ptr = ret >>> 0;
|
|
3181
|
-
MessageFinalization.register(this, this.__wbg_ptr, this);
|
|
3182
|
-
return this;
|
|
3183
|
-
}
|
|
3184
|
-
}
|
|
3185
|
-
|
|
3186
|
-
const MessageDisappearingSettingsFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
3187
|
-
? { register: () => {}, unregister: () => {} }
|
|
3188
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_messagedisappearingsettings_free(ptr >>> 0, 1));
|
|
3189
|
-
|
|
3190
|
-
export class MessageDisappearingSettings {
|
|
3191
|
-
|
|
3192
|
-
static __wrap(ptr) {
|
|
3193
|
-
ptr = ptr >>> 0;
|
|
3194
|
-
const obj = Object.create(MessageDisappearingSettings.prototype);
|
|
3195
|
-
obj.__wbg_ptr = ptr;
|
|
3196
|
-
MessageDisappearingSettingsFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
3197
|
-
return obj;
|
|
3198
|
-
}
|
|
3199
|
-
|
|
3200
|
-
__destroy_into_raw() {
|
|
3201
|
-
const ptr = this.__wbg_ptr;
|
|
3202
|
-
this.__wbg_ptr = 0;
|
|
3203
|
-
MessageDisappearingSettingsFinalization.unregister(this);
|
|
3204
|
-
return ptr;
|
|
3205
|
-
}
|
|
3206
|
-
|
|
3207
|
-
free() {
|
|
3208
|
-
const ptr = this.__destroy_into_raw();
|
|
3209
|
-
wasm.__wbg_messagedisappearingsettings_free(ptr, 0);
|
|
3210
|
-
}
|
|
3211
|
-
/**
|
|
3212
|
-
* @returns {bigint}
|
|
3213
|
-
*/
|
|
3214
|
-
get from_ns() {
|
|
3215
|
-
const ret = wasm.__wbg_get_hmackey_epoch(this.__wbg_ptr);
|
|
3216
|
-
return ret;
|
|
3217
|
-
}
|
|
3218
|
-
/**
|
|
3219
|
-
* @param {bigint} arg0
|
|
3220
|
-
*/
|
|
3221
|
-
set from_ns(arg0) {
|
|
3222
|
-
wasm.__wbg_set_hmackey_epoch(this.__wbg_ptr, arg0);
|
|
3223
|
-
}
|
|
3224
|
-
/**
|
|
3225
|
-
* @returns {bigint}
|
|
3226
|
-
*/
|
|
3227
|
-
get in_ns() {
|
|
3228
|
-
const ret = wasm.__wbg_get_messagedisappearingsettings_in_ns(this.__wbg_ptr);
|
|
3229
|
-
return ret;
|
|
3230
|
-
}
|
|
3231
|
-
/**
|
|
3232
|
-
* @param {bigint} arg0
|
|
3233
|
-
*/
|
|
3234
|
-
set in_ns(arg0) {
|
|
3235
|
-
wasm.__wbg_set_messagedisappearingsettings_in_ns(this.__wbg_ptr, arg0);
|
|
3236
|
-
}
|
|
3237
|
-
/**
|
|
3238
|
-
* @param {bigint} from_ns
|
|
3239
|
-
* @param {bigint} in_ns
|
|
3240
|
-
*/
|
|
3241
|
-
constructor(from_ns, in_ns) {
|
|
3242
|
-
const ret = wasm.messagedisappearingsettings_new(from_ns, in_ns);
|
|
3243
|
-
this.__wbg_ptr = ret >>> 0;
|
|
3244
|
-
MessageDisappearingSettingsFinalization.register(this, this.__wbg_ptr, this);
|
|
3245
|
-
return this;
|
|
3246
|
-
}
|
|
3247
|
-
}
|
|
3248
|
-
|
|
3249
|
-
const PermissionPolicySetFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
3250
|
-
? { register: () => {}, unregister: () => {} }
|
|
3251
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_permissionpolicyset_free(ptr >>> 0, 1));
|
|
3252
|
-
|
|
3253
|
-
export class PermissionPolicySet {
|
|
3254
|
-
|
|
3255
|
-
static __wrap(ptr) {
|
|
3256
|
-
ptr = ptr >>> 0;
|
|
3257
|
-
const obj = Object.create(PermissionPolicySet.prototype);
|
|
3258
|
-
obj.__wbg_ptr = ptr;
|
|
3259
|
-
PermissionPolicySetFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
3260
|
-
return obj;
|
|
3261
|
-
}
|
|
3262
|
-
|
|
3263
|
-
__destroy_into_raw() {
|
|
3264
|
-
const ptr = this.__wbg_ptr;
|
|
3265
|
-
this.__wbg_ptr = 0;
|
|
3266
|
-
PermissionPolicySetFinalization.unregister(this);
|
|
3267
|
-
return ptr;
|
|
3268
|
-
}
|
|
3269
|
-
|
|
3270
|
-
free() {
|
|
3271
|
-
const ptr = this.__destroy_into_raw();
|
|
3272
|
-
wasm.__wbg_permissionpolicyset_free(ptr, 0);
|
|
3273
|
-
}
|
|
3274
|
-
/**
|
|
3275
|
-
* @returns {PermissionPolicy}
|
|
3276
|
-
*/
|
|
3277
|
-
get addMemberPolicy() {
|
|
3278
|
-
const ret = wasm.__wbg_get_permissionpolicyset_addMemberPolicy(this.__wbg_ptr);
|
|
3279
|
-
return ret;
|
|
3280
|
-
}
|
|
3281
|
-
/**
|
|
3282
|
-
* @param {PermissionPolicy} arg0
|
|
3283
|
-
*/
|
|
3284
|
-
set addMemberPolicy(arg0) {
|
|
3285
|
-
wasm.__wbg_set_permissionpolicyset_addMemberPolicy(this.__wbg_ptr, arg0);
|
|
3286
|
-
}
|
|
3287
|
-
/**
|
|
3288
|
-
* @returns {PermissionPolicy}
|
|
3289
|
-
*/
|
|
3290
|
-
get removeMemberPolicy() {
|
|
3291
|
-
const ret = wasm.__wbg_get_permissionpolicyset_removeMemberPolicy(this.__wbg_ptr);
|
|
3292
|
-
return ret;
|
|
3293
|
-
}
|
|
3294
|
-
/**
|
|
3295
|
-
* @param {PermissionPolicy} arg0
|
|
3296
|
-
*/
|
|
3297
|
-
set removeMemberPolicy(arg0) {
|
|
3298
|
-
wasm.__wbg_set_permissionpolicyset_removeMemberPolicy(this.__wbg_ptr, arg0);
|
|
3299
|
-
}
|
|
3300
|
-
/**
|
|
3301
|
-
* @returns {PermissionPolicy}
|
|
3302
|
-
*/
|
|
3303
|
-
get addAdminPolicy() {
|
|
3304
|
-
const ret = wasm.__wbg_get_permissionpolicyset_addAdminPolicy(this.__wbg_ptr);
|
|
3305
|
-
return ret;
|
|
3306
|
-
}
|
|
3307
|
-
/**
|
|
3308
|
-
* @param {PermissionPolicy} arg0
|
|
3309
|
-
*/
|
|
3310
|
-
set addAdminPolicy(arg0) {
|
|
3311
|
-
wasm.__wbg_set_permissionpolicyset_addAdminPolicy(this.__wbg_ptr, arg0);
|
|
3312
|
-
}
|
|
3313
|
-
/**
|
|
3314
|
-
* @returns {PermissionPolicy}
|
|
3315
|
-
*/
|
|
3316
|
-
get removeAdminPolicy() {
|
|
3317
|
-
const ret = wasm.__wbg_get_permissionpolicyset_removeAdminPolicy(this.__wbg_ptr);
|
|
3318
|
-
return ret;
|
|
3319
|
-
}
|
|
3320
|
-
/**
|
|
3321
|
-
* @param {PermissionPolicy} arg0
|
|
3322
|
-
*/
|
|
3323
|
-
set removeAdminPolicy(arg0) {
|
|
3324
|
-
wasm.__wbg_set_permissionpolicyset_removeAdminPolicy(this.__wbg_ptr, arg0);
|
|
3325
|
-
}
|
|
3326
|
-
/**
|
|
3327
|
-
* @returns {PermissionPolicy}
|
|
3328
|
-
*/
|
|
3329
|
-
get updateGroupNamePolicy() {
|
|
3330
|
-
const ret = wasm.__wbg_get_permissionpolicyset_updateGroupNamePolicy(this.__wbg_ptr);
|
|
3331
|
-
return ret;
|
|
3332
|
-
}
|
|
3333
|
-
/**
|
|
3334
|
-
* @param {PermissionPolicy} arg0
|
|
3335
|
-
*/
|
|
3336
|
-
set updateGroupNamePolicy(arg0) {
|
|
3337
|
-
wasm.__wbg_set_permissionpolicyset_updateGroupNamePolicy(this.__wbg_ptr, arg0);
|
|
3338
|
-
}
|
|
3339
|
-
/**
|
|
3340
|
-
* @returns {PermissionPolicy}
|
|
3341
|
-
*/
|
|
3342
|
-
get updateGroupDescriptionPolicy() {
|
|
3343
|
-
const ret = wasm.__wbg_get_permissionpolicyset_updateGroupDescriptionPolicy(this.__wbg_ptr);
|
|
3344
|
-
return ret;
|
|
3345
|
-
}
|
|
3346
|
-
/**
|
|
3347
|
-
* @param {PermissionPolicy} arg0
|
|
3348
|
-
*/
|
|
3349
|
-
set updateGroupDescriptionPolicy(arg0) {
|
|
3350
|
-
wasm.__wbg_set_permissionpolicyset_updateGroupDescriptionPolicy(this.__wbg_ptr, arg0);
|
|
3351
|
-
}
|
|
3352
|
-
/**
|
|
3353
|
-
* @returns {PermissionPolicy}
|
|
3354
|
-
*/
|
|
3355
|
-
get updateGroupImageUrlSquarePolicy() {
|
|
3356
|
-
const ret = wasm.__wbg_get_permissionpolicyset_updateGroupImageUrlSquarePolicy(this.__wbg_ptr);
|
|
3357
|
-
return ret;
|
|
3358
|
-
}
|
|
3359
|
-
/**
|
|
3360
|
-
* @param {PermissionPolicy} arg0
|
|
3361
|
-
*/
|
|
3362
|
-
set updateGroupImageUrlSquarePolicy(arg0) {
|
|
3363
|
-
wasm.__wbg_set_permissionpolicyset_updateGroupImageUrlSquarePolicy(this.__wbg_ptr, arg0);
|
|
3364
|
-
}
|
|
3365
|
-
/**
|
|
3366
|
-
* @returns {PermissionPolicy}
|
|
3367
|
-
*/
|
|
3368
|
-
get updateMessageDisappearingPolicy() {
|
|
3369
|
-
const ret = wasm.__wbg_get_permissionpolicyset_updateMessageDisappearingPolicy(this.__wbg_ptr);
|
|
3370
|
-
return ret;
|
|
3371
|
-
}
|
|
3372
|
-
/**
|
|
3373
|
-
* @param {PermissionPolicy} arg0
|
|
3374
|
-
*/
|
|
3375
|
-
set updateMessageDisappearingPolicy(arg0) {
|
|
3376
|
-
wasm.__wbg_set_permissionpolicyset_updateMessageDisappearingPolicy(this.__wbg_ptr, arg0);
|
|
3377
|
-
}
|
|
3378
|
-
/**
|
|
3379
|
-
* @param {PermissionPolicy} add_member_policy
|
|
3380
|
-
* @param {PermissionPolicy} remove_member_policy
|
|
3381
|
-
* @param {PermissionPolicy} add_admin_policy
|
|
3382
|
-
* @param {PermissionPolicy} remove_admin_policy
|
|
3383
|
-
* @param {PermissionPolicy} update_group_name_policy
|
|
3384
|
-
* @param {PermissionPolicy} update_group_description_policy
|
|
3385
|
-
* @param {PermissionPolicy} update_group_image_url_square_policy
|
|
3386
|
-
* @param {PermissionPolicy} update_message_disappearing_policy
|
|
3387
|
-
*/
|
|
3388
|
-
constructor(add_member_policy, remove_member_policy, add_admin_policy, remove_admin_policy, update_group_name_policy, update_group_description_policy, update_group_image_url_square_policy, update_message_disappearing_policy) {
|
|
3389
|
-
const ret = wasm.permissionpolicyset_new(add_member_policy, remove_member_policy, add_admin_policy, remove_admin_policy, update_group_name_policy, update_group_description_policy, update_group_image_url_square_policy, update_message_disappearing_policy);
|
|
3390
|
-
this.__wbg_ptr = ret >>> 0;
|
|
3391
|
-
PermissionPolicySetFinalization.register(this, this.__wbg_ptr, this);
|
|
3392
|
-
return this;
|
|
3393
|
-
}
|
|
3394
|
-
}
|
|
3395
|
-
|
|
3396
|
-
const StreamCloserFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
3397
|
-
? { register: () => {}, unregister: () => {} }
|
|
3398
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_streamcloser_free(ptr >>> 0, 1));
|
|
3399
|
-
|
|
3400
|
-
export class StreamCloser {
|
|
3401
|
-
|
|
3402
|
-
static __wrap(ptr) {
|
|
3403
|
-
ptr = ptr >>> 0;
|
|
3404
|
-
const obj = Object.create(StreamCloser.prototype);
|
|
3405
|
-
obj.__wbg_ptr = ptr;
|
|
3406
|
-
StreamCloserFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
3407
|
-
return obj;
|
|
3408
|
-
}
|
|
3409
|
-
|
|
3410
|
-
__destroy_into_raw() {
|
|
3411
|
-
const ptr = this.__wbg_ptr;
|
|
3412
|
-
this.__wbg_ptr = 0;
|
|
3413
|
-
StreamCloserFinalization.unregister(this);
|
|
3414
|
-
return ptr;
|
|
3415
|
-
}
|
|
3416
|
-
|
|
3417
|
-
free() {
|
|
3418
|
-
const ptr = this.__destroy_into_raw();
|
|
3419
|
-
wasm.__wbg_streamcloser_free(ptr, 0);
|
|
3420
|
-
}
|
|
3421
|
-
/**
|
|
3422
|
-
* Signal the stream to end
|
|
3423
|
-
* Does not wait for the stream to end.
|
|
3424
|
-
*/
|
|
3425
|
-
end() {
|
|
3426
|
-
wasm.streamcloser_end(this.__wbg_ptr);
|
|
3427
|
-
}
|
|
3428
|
-
/**
|
|
3429
|
-
* End the stream and `await` for it to shutdown
|
|
3430
|
-
* Returns the `Result` of the task.
|
|
3431
|
-
* End the stream and asynchronously wait for it to shutdown
|
|
3432
|
-
* @returns {Promise<void>}
|
|
3433
|
-
*/
|
|
3434
|
-
endAndWait() {
|
|
3435
|
-
const ret = wasm.streamcloser_endAndWait(this.__wbg_ptr);
|
|
3436
|
-
return ret;
|
|
3437
|
-
}
|
|
3438
|
-
/**
|
|
3439
|
-
* @returns {Promise<void>}
|
|
3440
|
-
*/
|
|
3441
|
-
waitForReady() {
|
|
3442
|
-
const ret = wasm.streamcloser_waitForReady(this.__wbg_ptr);
|
|
3443
|
-
return ret;
|
|
3444
|
-
}
|
|
3445
|
-
/**
|
|
3446
|
-
* Checks if this stream is closed
|
|
3447
|
-
* @returns {boolean}
|
|
3448
|
-
*/
|
|
3449
|
-
isClosed() {
|
|
3450
|
-
const ret = wasm.streamcloser_isClosed(this.__wbg_ptr);
|
|
3451
|
-
return ret !== 0;
|
|
3452
|
-
}
|
|
3453
|
-
}
|
|
3454
|
-
|
|
3455
|
-
const VersionFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
3456
|
-
? { register: () => {}, unregister: () => {} }
|
|
3457
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_version_free(ptr >>> 0, 1));
|
|
3458
|
-
|
|
3459
|
-
export class Version {
|
|
3460
|
-
|
|
3461
|
-
__destroy_into_raw() {
|
|
3462
|
-
const ptr = this.__wbg_ptr;
|
|
3463
|
-
this.__wbg_ptr = 0;
|
|
3464
|
-
VersionFinalization.unregister(this);
|
|
3465
|
-
return ptr;
|
|
3466
|
-
}
|
|
3467
|
-
|
|
3468
|
-
free() {
|
|
3469
|
-
const ptr = this.__destroy_into_raw();
|
|
3470
|
-
wasm.__wbg_version_free(ptr, 0);
|
|
3471
|
-
}
|
|
3472
|
-
}
|
|
3473
|
-
|
|
3474
|
-
async function __wbg_load(module, imports) {
|
|
3475
|
-
if (typeof Response === 'function' && module instanceof Response) {
|
|
3476
|
-
if (typeof WebAssembly.instantiateStreaming === 'function') {
|
|
3477
|
-
try {
|
|
3478
|
-
return await WebAssembly.instantiateStreaming(module, imports);
|
|
3479
|
-
|
|
3480
|
-
} catch (e) {
|
|
3481
|
-
if (module.headers.get('Content-Type') != 'application/wasm') {
|
|
3482
|
-
console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve Wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n", e);
|
|
3483
|
-
|
|
3484
|
-
} else {
|
|
3485
|
-
throw e;
|
|
3486
|
-
}
|
|
3487
|
-
}
|
|
3488
|
-
}
|
|
3489
|
-
|
|
3490
|
-
const bytes = await module.arrayBuffer();
|
|
3491
|
-
return await WebAssembly.instantiate(bytes, imports);
|
|
3492
|
-
|
|
3493
|
-
} else {
|
|
3494
|
-
const instance = await WebAssembly.instantiate(module, imports);
|
|
3495
|
-
|
|
3496
|
-
if (instance instanceof WebAssembly.Instance) {
|
|
3497
|
-
return { instance, module };
|
|
3498
|
-
|
|
3499
|
-
} else {
|
|
3500
|
-
return instance;
|
|
3501
|
-
}
|
|
3502
|
-
}
|
|
3503
|
-
}
|
|
3504
|
-
|
|
3505
|
-
function __wbg_get_imports() {
|
|
3506
|
-
const imports = {};
|
|
3507
|
-
imports.wbg = {};
|
|
3508
|
-
imports.wbg.__wbg_SQLITEBLOB_6acbdf0084499c6d = function(arg0) {
|
|
3509
|
-
const ret = arg0.SQLITE_BLOB;
|
|
3510
|
-
return ret;
|
|
3511
|
-
};
|
|
3512
|
-
imports.wbg.__wbg_SQLITECONSTRAINTCHECK_078c7421516c6cb0 = function(arg0) {
|
|
3513
|
-
const ret = arg0.SQLITE_CONSTRAINT_CHECK;
|
|
3514
|
-
return ret;
|
|
3515
|
-
};
|
|
3516
|
-
imports.wbg.__wbg_SQLITECONSTRAINTFOREIGNKEY_542d05e3ee2cb739 = function(arg0) {
|
|
3517
|
-
const ret = arg0.SQLITE_CONSTRAINT_FOREIGNKEY;
|
|
3518
|
-
return ret;
|
|
3519
|
-
};
|
|
3520
|
-
imports.wbg.__wbg_SQLITECONSTRAINTNOTNULL_2e70f645b6727cc2 = function(arg0) {
|
|
3521
|
-
const ret = arg0.SQLITE_CONSTRAINT_NOTNULL;
|
|
3522
|
-
return ret;
|
|
3523
|
-
};
|
|
3524
|
-
imports.wbg.__wbg_SQLITECONSTRAINTPRIMARYKEY_672b0b877eaa70c2 = function(arg0) {
|
|
3525
|
-
const ret = arg0.SQLITE_CONSTRAINT_PRIMARYKEY;
|
|
3526
|
-
return ret;
|
|
3527
|
-
};
|
|
3528
|
-
imports.wbg.__wbg_SQLITECONSTRAINTUNIQUE_99e8e64a3ddb260e = function(arg0) {
|
|
3529
|
-
const ret = arg0.SQLITE_CONSTRAINT_UNIQUE;
|
|
3530
|
-
return ret;
|
|
3531
|
-
};
|
|
3532
|
-
imports.wbg.__wbg_SQLITEDONE_71e1fe762c2f590a = function(arg0) {
|
|
3533
|
-
const ret = arg0.SQLITE_DONE;
|
|
3534
|
-
return ret;
|
|
3535
|
-
};
|
|
3536
|
-
imports.wbg.__wbg_SQLITEFLOAT_0d1b783b6273c5ca = function(arg0) {
|
|
3537
|
-
const ret = arg0.SQLITE_FLOAT;
|
|
3538
|
-
return ret;
|
|
3539
|
-
};
|
|
3540
|
-
imports.wbg.__wbg_SQLITEINTEGER_89d30a97ec5964fa = function(arg0) {
|
|
3541
|
-
const ret = arg0.SQLITE_INTEGER;
|
|
3542
|
-
return ret;
|
|
3543
|
-
};
|
|
3544
|
-
imports.wbg.__wbg_SQLITENULL_14a0b14e9418f512 = function(arg0) {
|
|
3545
|
-
const ret = arg0.SQLITE_NULL;
|
|
3546
|
-
return ret;
|
|
3547
|
-
};
|
|
3548
|
-
imports.wbg.__wbg_SQLITEOK_a0a5a44f4b54bda1 = function(arg0) {
|
|
3549
|
-
const ret = arg0.SQLITE_OK;
|
|
3550
|
-
return ret;
|
|
3551
|
-
};
|
|
3552
|
-
imports.wbg.__wbg_SQLITEOPENCREATE_a89e637416473d65 = function(arg0) {
|
|
3553
|
-
const ret = arg0.SQLITE_OPEN_CREATE;
|
|
3554
|
-
return ret;
|
|
3555
|
-
};
|
|
3556
|
-
imports.wbg.__wbg_SQLITEOPENREADWRITE_3eb06e2be4a7f535 = function(arg0) {
|
|
3557
|
-
const ret = arg0.SQLITE_OPEN_READWRITE;
|
|
3558
|
-
return ret;
|
|
3559
|
-
};
|
|
3560
|
-
imports.wbg.__wbg_SQLITEOPENURI_73f78cdcb3e54f88 = function(arg0) {
|
|
3561
|
-
const ret = arg0.SQLITE_OPEN_URI;
|
|
3562
|
-
return ret;
|
|
3563
|
-
};
|
|
3564
|
-
imports.wbg.__wbg_SQLITEPREPAREPERSISTENT_6f142d8bf27893d7 = function(arg0) {
|
|
3565
|
-
const ret = arg0.SQLITE_PREPARE_PERSISTENT;
|
|
3566
|
-
return ret;
|
|
3567
|
-
};
|
|
3568
|
-
imports.wbg.__wbg_SQLITEROW_16ddd22277b912f1 = function(arg0) {
|
|
3569
|
-
const ret = arg0.SQLITE_ROW;
|
|
3570
|
-
return ret;
|
|
3571
|
-
};
|
|
3572
|
-
imports.wbg.__wbg_SQLITESTATIC_f6e96ea3ff678329 = function(arg0) {
|
|
3573
|
-
const ret = arg0.SQLITE_STATIC;
|
|
3574
|
-
return ret;
|
|
3575
|
-
};
|
|
3576
|
-
imports.wbg.__wbg_SQLITETEXT_4dd38105410a0c0a = function(arg0) {
|
|
3577
|
-
const ret = arg0.SQLITE_TEXT;
|
|
3578
|
-
return ret;
|
|
3579
|
-
};
|
|
3580
|
-
imports.wbg.__wbg_String_8f0eb39a4a4c2f66 = function(arg0, arg1) {
|
|
3581
|
-
const ret = String(arg1);
|
|
3582
|
-
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
3583
|
-
const len1 = WASM_VECTOR_LEN;
|
|
3584
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
3585
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
3586
|
-
};
|
|
3587
|
-
imports.wbg.__wbg_abort_775ef1d17fc65868 = function(arg0) {
|
|
3588
|
-
arg0.abort();
|
|
3589
|
-
};
|
|
3590
|
-
imports.wbg.__wbg_allocCString_69f9010fb2b096f0 = function(arg0, arg1, arg2) {
|
|
3591
|
-
let deferred0_0;
|
|
3592
|
-
let deferred0_1;
|
|
3593
|
-
try {
|
|
3594
|
-
deferred0_0 = arg1;
|
|
3595
|
-
deferred0_1 = arg2;
|
|
3596
|
-
const ret = arg0.allocCString(getStringFromWasm0(arg1, arg2));
|
|
3597
|
-
return ret;
|
|
3598
|
-
} finally {
|
|
3599
|
-
wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
|
|
3600
|
-
}
|
|
3601
|
-
};
|
|
3602
|
-
imports.wbg.__wbg_allocPtr_c83ee345784d444f = function(arg0, arg1, arg2) {
|
|
3603
|
-
const ret = arg0.allocPtr(arg1 >>> 0, arg2 !== 0);
|
|
3604
|
-
return ret;
|
|
3605
|
-
};
|
|
3606
|
-
imports.wbg.__wbg_alloc_59459fd5c596f36c = function(arg0, arg1) {
|
|
3607
|
-
const ret = arg0.alloc(arg1 >>> 0);
|
|
3608
|
-
return ret;
|
|
3609
|
-
};
|
|
3610
|
-
imports.wbg.__wbg_alloc_818f07788ede8415 = function(arg0, arg1) {
|
|
3611
|
-
const ret = arg0.alloc(arg1 >>> 0);
|
|
3612
|
-
return ret;
|
|
3613
|
-
};
|
|
3614
|
-
imports.wbg.__wbg_alloc_9ba78eb5db297dec = function(arg0) {
|
|
3615
|
-
const ret = arg0.alloc;
|
|
3616
|
-
return ret;
|
|
3617
|
-
};
|
|
3618
|
-
imports.wbg.__wbg_append_8c7dd8d641a5f01b = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
|
|
3619
|
-
arg0.append(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4));
|
|
3620
|
-
}, arguments) };
|
|
3621
|
-
imports.wbg.__wbg_arrayBuffer_d1b44c4390db422f = function() { return handleError(function (arg0) {
|
|
3622
|
-
const ret = arg0.arrayBuffer();
|
|
3623
|
-
return ret;
|
|
3624
|
-
}, arguments) };
|
|
3625
|
-
imports.wbg.__wbg_bindblob_2d3842f5d0645344 = function(arg0, arg1, arg2, arg3, arg4, arg5) {
|
|
3626
|
-
const ret = arg0.bind_blob(arg1, arg2, arg3 >>> 0, arg4, arg5);
|
|
3627
|
-
return ret;
|
|
3628
|
-
};
|
|
3629
|
-
imports.wbg.__wbg_binddouble_652de2eaf823b755 = function(arg0, arg1, arg2, arg3) {
|
|
3630
|
-
const ret = arg0.bind_double(arg1, arg2, arg3);
|
|
3631
|
-
return ret;
|
|
3632
|
-
};
|
|
3633
|
-
imports.wbg.__wbg_bindint64_ab19debe2f3b2a51 = function(arg0, arg1, arg2, arg3) {
|
|
3634
|
-
const ret = arg0.bind_int64(arg1, arg2, arg3);
|
|
3635
|
-
return ret;
|
|
3636
|
-
};
|
|
3637
|
-
imports.wbg.__wbg_bindint_d6ed3d7de087f452 = function(arg0, arg1, arg2, arg3) {
|
|
3638
|
-
const ret = arg0.bind_int(arg1, arg2, arg3);
|
|
3639
|
-
return ret;
|
|
3640
|
-
};
|
|
3641
|
-
imports.wbg.__wbg_bindnull_db900eeb1a7f0781 = function(arg0, arg1, arg2) {
|
|
3642
|
-
const ret = arg0.bind_null(arg1, arg2);
|
|
3643
|
-
return ret;
|
|
3644
|
-
};
|
|
3645
|
-
imports.wbg.__wbg_bindtext_d7063f12780d715d = function(arg0, arg1, arg2, arg3, arg4, arg5) {
|
|
3646
|
-
const ret = arg0.bind_text(arg1, arg2, arg3 >>> 0, arg4, arg5);
|
|
3647
|
-
return ret;
|
|
3648
|
-
};
|
|
3649
|
-
imports.wbg.__wbg_body_0b8fd1fe671660df = function(arg0) {
|
|
3650
|
-
const ret = arg0.body;
|
|
3651
|
-
return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
|
|
3652
|
-
};
|
|
3653
|
-
imports.wbg.__wbg_buffer_09165b52af8c5237 = function(arg0) {
|
|
3654
|
-
const ret = arg0.buffer;
|
|
3655
|
-
return ret;
|
|
3656
|
-
};
|
|
3657
|
-
imports.wbg.__wbg_buffer_609cc3eee51ed158 = function(arg0) {
|
|
3658
|
-
const ret = arg0.buffer;
|
|
3659
|
-
return ret;
|
|
3660
|
-
};
|
|
3661
|
-
imports.wbg.__wbg_byobRequest_77d9adf63337edfb = function(arg0) {
|
|
3662
|
-
const ret = arg0.byobRequest;
|
|
3663
|
-
return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
|
|
3664
|
-
};
|
|
3665
|
-
imports.wbg.__wbg_byteLength_e674b853d9c77e1d = function(arg0) {
|
|
3666
|
-
const ret = arg0.byteLength;
|
|
3667
|
-
return ret;
|
|
3668
|
-
};
|
|
3669
|
-
imports.wbg.__wbg_byteOffset_fd862df290ef848d = function(arg0) {
|
|
3670
|
-
const ret = arg0.byteOffset;
|
|
3671
|
-
return ret;
|
|
3672
|
-
};
|
|
3673
|
-
imports.wbg.__wbg_call_672a4d21634d4a24 = function() { return handleError(function (arg0, arg1) {
|
|
3674
|
-
const ret = arg0.call(arg1);
|
|
3675
|
-
return ret;
|
|
3676
|
-
}, arguments) };
|
|
3677
|
-
imports.wbg.__wbg_call_7cccdd69e0791ae2 = function() { return handleError(function (arg0, arg1, arg2) {
|
|
3678
|
-
const ret = arg0.call(arg1, arg2);
|
|
3679
|
-
return ret;
|
|
3680
|
-
}, arguments) };
|
|
3681
|
-
imports.wbg.__wbg_cancel_8a308660caa6cadf = function(arg0) {
|
|
3682
|
-
const ret = arg0.cancel();
|
|
3683
|
-
return ret;
|
|
3684
|
-
};
|
|
3685
|
-
imports.wbg.__wbg_capi_b2cd9cd3325d1164 = function(arg0) {
|
|
3686
|
-
const ret = arg0.capi;
|
|
3687
|
-
return ret;
|
|
3688
|
-
};
|
|
3689
|
-
imports.wbg.__wbg_catch_a6e601879b2610e9 = function(arg0, arg1) {
|
|
3690
|
-
const ret = arg0.catch(arg1);
|
|
3691
|
-
return ret;
|
|
3692
|
-
};
|
|
3693
|
-
imports.wbg.__wbg_changes_8f2cadd92748538c = function(arg0, arg1) {
|
|
3694
|
-
const ret = arg0.changes(arg1);
|
|
3695
|
-
return ret;
|
|
3696
|
-
};
|
|
3697
|
-
imports.wbg.__wbg_clearInterval_dd1e598f425db353 = function(arg0) {
|
|
3698
|
-
const ret = clearInterval(arg0);
|
|
3699
|
-
return ret;
|
|
3700
|
-
};
|
|
3701
|
-
imports.wbg.__wbg_clearTimeout_5a54f8841c30079a = function(arg0) {
|
|
3702
|
-
const ret = clearTimeout(arg0);
|
|
3703
|
-
return ret;
|
|
3704
|
-
};
|
|
3705
|
-
imports.wbg.__wbg_client_new = function(arg0) {
|
|
3706
|
-
const ret = Client.__wrap(arg0);
|
|
3707
|
-
return ret;
|
|
3708
|
-
};
|
|
3709
|
-
imports.wbg.__wbg_close_061ae3ddcd90d5b9 = function(arg0, arg1) {
|
|
3710
|
-
const ret = arg0.close(arg1);
|
|
3711
|
-
return ret;
|
|
3712
|
-
};
|
|
3713
|
-
imports.wbg.__wbg_close_304cc1fef3466669 = function() { return handleError(function (arg0) {
|
|
3714
|
-
arg0.close();
|
|
3715
|
-
}, arguments) };
|
|
3716
|
-
imports.wbg.__wbg_close_5ce03e29be453811 = function() { return handleError(function (arg0) {
|
|
3717
|
-
arg0.close();
|
|
3718
|
-
}, arguments) };
|
|
3719
|
-
imports.wbg.__wbg_columncount_328a9b2639ca5c51 = function(arg0, arg1) {
|
|
3720
|
-
const ret = arg0.column_count(arg1);
|
|
3721
|
-
return ret;
|
|
3722
|
-
};
|
|
3723
|
-
imports.wbg.__wbg_columnname_5421a5f0dfa3eff5 = function(arg0, arg1, arg2, arg3) {
|
|
3724
|
-
const ret = arg1.column_name(arg2, arg3);
|
|
3725
|
-
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
3726
|
-
const len1 = WASM_VECTOR_LEN;
|
|
3727
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
3728
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
3729
|
-
};
|
|
3730
|
-
imports.wbg.__wbg_columnvalue_88aa9511cf9c6770 = function(arg0, arg1, arg2) {
|
|
3731
|
-
const ret = arg0.column_value(arg1, arg2);
|
|
3732
|
-
return ret;
|
|
3733
|
-
};
|
|
3734
|
-
imports.wbg.__wbg_consent_unwrap = function(arg0) {
|
|
3735
|
-
const ret = Consent.__unwrap(arg0);
|
|
3736
|
-
return ret;
|
|
3737
|
-
};
|
|
3738
|
-
imports.wbg.__wbg_conversation_new = function(arg0) {
|
|
3739
|
-
const ret = Conversation.__wrap(arg0);
|
|
3740
|
-
return ret;
|
|
3741
|
-
};
|
|
3742
|
-
imports.wbg.__wbg_conversationlistitem_new = function(arg0) {
|
|
3743
|
-
const ret = ConversationListItem.__wrap(arg0);
|
|
3744
|
-
return ret;
|
|
3745
|
-
};
|
|
3746
|
-
imports.wbg.__wbg_create_cfe43ccc88c64e0a = function(arg0) {
|
|
3747
|
-
const ret = Object.create(arg0);
|
|
3748
|
-
return ret;
|
|
3749
|
-
};
|
|
3750
|
-
imports.wbg.__wbg_crypto_ed58b8e10a292839 = function(arg0) {
|
|
3751
|
-
const ret = arg0.crypto;
|
|
3752
|
-
return ret;
|
|
3753
|
-
};
|
|
3754
|
-
imports.wbg.__wbg_dbhandle_4a844bc7b495c9bd = function(arg0, arg1) {
|
|
3755
|
-
const ret = arg0.db_handle(arg1);
|
|
3756
|
-
return ret;
|
|
3757
|
-
};
|
|
3758
|
-
imports.wbg.__wbg_dealloc_83aa46cc9ca6df71 = function(arg0, arg1) {
|
|
3759
|
-
arg0.dealloc(arg1 >>> 0);
|
|
3760
|
-
};
|
|
3761
|
-
imports.wbg.__wbg_debug_3cb59063b29f58c1 = function(arg0) {
|
|
3762
|
-
console.debug(arg0);
|
|
3763
|
-
};
|
|
3764
|
-
imports.wbg.__wbg_debug_e17b51583ca6a632 = function(arg0, arg1, arg2, arg3) {
|
|
3765
|
-
console.debug(arg0, arg1, arg2, arg3);
|
|
3766
|
-
};
|
|
3767
|
-
imports.wbg.__wbg_done_769e5ede4b31c67b = function(arg0) {
|
|
3768
|
-
const ret = arg0.done;
|
|
3769
|
-
return ret;
|
|
3770
|
-
};
|
|
3771
|
-
imports.wbg.__wbg_enqueue_bb16ba72f537dc9e = function() { return handleError(function (arg0, arg1) {
|
|
3772
|
-
arg0.enqueue(arg1);
|
|
3773
|
-
}, arguments) };
|
|
3774
|
-
imports.wbg.__wbg_entries_3265d4158b33e5dc = function(arg0) {
|
|
3775
|
-
const ret = Object.entries(arg0);
|
|
3776
|
-
return ret;
|
|
3777
|
-
};
|
|
3778
|
-
imports.wbg.__wbg_errmsg_79ea90bf7680bb35 = function(arg0, arg1, arg2) {
|
|
3779
|
-
const ret = arg1.errmsg(arg2);
|
|
3780
|
-
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
3781
|
-
const len1 = WASM_VECTOR_LEN;
|
|
3782
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
3783
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
3784
|
-
};
|
|
3785
|
-
imports.wbg.__wbg_error_524f506f44df1645 = function(arg0) {
|
|
3786
|
-
console.error(arg0);
|
|
3787
|
-
};
|
|
3788
|
-
imports.wbg.__wbg_error_7534b8e9a36f1ab4 = function(arg0, arg1) {
|
|
3789
|
-
let deferred0_0;
|
|
3790
|
-
let deferred0_1;
|
|
3791
|
-
try {
|
|
3792
|
-
deferred0_0 = arg0;
|
|
3793
|
-
deferred0_1 = arg1;
|
|
3794
|
-
console.error(getStringFromWasm0(arg0, arg1));
|
|
3795
|
-
} finally {
|
|
3796
|
-
wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
|
|
3797
|
-
}
|
|
3798
|
-
};
|
|
3799
|
-
imports.wbg.__wbg_error_80de38b3f7cc3c3c = function(arg0, arg1, arg2, arg3) {
|
|
3800
|
-
console.error(arg0, arg1, arg2, arg3);
|
|
3801
|
-
};
|
|
3802
|
-
imports.wbg.__wbg_errstr_503ebc5fc9ad1b72 = function(arg0, arg1, arg2) {
|
|
3803
|
-
const ret = arg1.errstr(arg2);
|
|
3804
|
-
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
3805
|
-
const len1 = WASM_VECTOR_LEN;
|
|
3806
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
3807
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
3808
|
-
};
|
|
3809
|
-
imports.wbg.__wbg_exec_fd553de4a4a4f848 = function() { return handleError(function (arg0, arg1, arg2, arg3) {
|
|
3810
|
-
arg0.exec(arg1, getStringFromWasm0(arg2, arg3));
|
|
3811
|
-
}, arguments) };
|
|
3812
|
-
imports.wbg.__wbg_extendederrcode_0835da64030ca814 = function(arg0, arg1) {
|
|
3813
|
-
const ret = arg0.extended_errcode(arg1);
|
|
3814
|
-
return ret;
|
|
3815
|
-
};
|
|
3816
|
-
imports.wbg.__wbg_fetch_4465c2b10f21a927 = function(arg0) {
|
|
3817
|
-
const ret = fetch(arg0);
|
|
3818
|
-
return ret;
|
|
3819
|
-
};
|
|
3820
|
-
imports.wbg.__wbg_fetch_509096533071c657 = function(arg0, arg1) {
|
|
3821
|
-
const ret = arg0.fetch(arg1);
|
|
3822
|
-
return ret;
|
|
3823
|
-
};
|
|
3824
|
-
imports.wbg.__wbg_filename_0235553cd4665109 = function(arg0, arg1, arg2, arg3, arg4) {
|
|
3825
|
-
let deferred0_0;
|
|
3826
|
-
let deferred0_1;
|
|
3827
|
-
try {
|
|
3828
|
-
deferred0_0 = arg3;
|
|
3829
|
-
deferred0_1 = arg4;
|
|
3830
|
-
const ret = arg1.filename(arg2, getStringFromWasm0(arg3, arg4));
|
|
3831
|
-
const ptr2 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
3832
|
-
const len2 = WASM_VECTOR_LEN;
|
|
3833
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 1, len2, true);
|
|
3834
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr2, true);
|
|
3835
|
-
} finally {
|
|
3836
|
-
wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
|
|
3837
|
-
}
|
|
3838
|
-
};
|
|
3839
|
-
imports.wbg.__wbg_finalize_429654d82c434d47 = function() { return handleError(function (arg0, arg1) {
|
|
3840
|
-
arg0.finalize(arg1);
|
|
3841
|
-
}, arguments) };
|
|
3842
|
-
imports.wbg.__wbg_getRandomValues_bcb4912f16000dc4 = function() { return handleError(function (arg0, arg1) {
|
|
3843
|
-
arg0.getRandomValues(arg1);
|
|
3844
|
-
}, arguments) };
|
|
3845
|
-
imports.wbg.__wbg_getReader_48e00749fe3f6089 = function() { return handleError(function (arg0) {
|
|
3846
|
-
const ret = arg0.getReader();
|
|
3847
|
-
return ret;
|
|
3848
|
-
}, arguments) };
|
|
3849
|
-
imports.wbg.__wbg_get_67b2ba62fc30de12 = function() { return handleError(function (arg0, arg1) {
|
|
3850
|
-
const ret = Reflect.get(arg0, arg1);
|
|
3851
|
-
return ret;
|
|
3852
|
-
}, arguments) };
|
|
3853
|
-
imports.wbg.__wbg_get_b9b93047fe3cf45b = function(arg0, arg1) {
|
|
3854
|
-
const ret = arg0[arg1 >>> 0];
|
|
3855
|
-
return ret;
|
|
3856
|
-
};
|
|
3857
|
-
imports.wbg.__wbg_getdone_d47073731acd3e74 = function(arg0) {
|
|
3858
|
-
const ret = arg0.done;
|
|
3859
|
-
return isLikeNone(ret) ? 0xFFFFFF : ret ? 1 : 0;
|
|
3860
|
-
};
|
|
3861
|
-
imports.wbg.__wbg_getvalue_009dcd63692bee1f = function(arg0) {
|
|
3862
|
-
const ret = arg0.value;
|
|
3863
|
-
return ret;
|
|
3864
|
-
};
|
|
3865
|
-
imports.wbg.__wbg_getwithrefkey_1dc361bd10053bfe = function(arg0, arg1) {
|
|
3866
|
-
const ret = arg0[arg1];
|
|
3867
|
-
return ret;
|
|
3868
|
-
};
|
|
3869
|
-
imports.wbg.__wbg_groupmetadata_new = function(arg0) {
|
|
3870
|
-
const ret = GroupMetadata.__wrap(arg0);
|
|
3871
|
-
return ret;
|
|
3872
|
-
};
|
|
3873
|
-
imports.wbg.__wbg_has_a5ea9117f258a0ec = function() { return handleError(function (arg0, arg1) {
|
|
3874
|
-
const ret = Reflect.has(arg0, arg1);
|
|
3875
|
-
return ret;
|
|
3876
|
-
}, arguments) };
|
|
3877
|
-
imports.wbg.__wbg_headers_9cb51cfd2ac780a4 = function(arg0) {
|
|
3878
|
-
const ret = arg0.headers;
|
|
3879
|
-
return ret;
|
|
3880
|
-
};
|
|
3881
|
-
imports.wbg.__wbg_heap8u_253de697ab096b05 = function(arg0) {
|
|
3882
|
-
const ret = arg0.heap8u();
|
|
3883
|
-
return ret;
|
|
3884
|
-
};
|
|
3885
|
-
imports.wbg.__wbg_impl_0cd08b475fc5f858 = function(arg0, arg1) {
|
|
3886
|
-
const ret = arg0.impl(arg1 >>> 0);
|
|
3887
|
-
return ret;
|
|
3888
|
-
};
|
|
3889
|
-
imports.wbg.__wbg_inboxstate_new = function(arg0) {
|
|
3890
|
-
const ret = InboxState.__wrap(arg0);
|
|
3891
|
-
return ret;
|
|
3892
|
-
};
|
|
3893
|
-
imports.wbg.__wbg_info_033d8b8a0838f1d3 = function(arg0, arg1, arg2, arg3) {
|
|
3894
|
-
console.info(arg0, arg1, arg2, arg3);
|
|
3895
|
-
};
|
|
3896
|
-
imports.wbg.__wbg_info_3daf2e093e091b66 = function(arg0) {
|
|
3897
|
-
console.info(arg0);
|
|
3898
|
-
};
|
|
3899
|
-
imports.wbg.__wbg_initmodule_694b4b8a6236ad25 = function(arg0) {
|
|
3900
|
-
const ret = SQLite.init_module(arg0);
|
|
3901
|
-
return ret;
|
|
3902
|
-
};
|
|
3903
|
-
imports.wbg.__wbg_installation_new = function(arg0) {
|
|
3904
|
-
const ret = Installation.__wrap(arg0);
|
|
3905
|
-
return ret;
|
|
3906
|
-
};
|
|
3907
|
-
imports.wbg.__wbg_installation_unwrap = function(arg0) {
|
|
3908
|
-
const ret = Installation.__unwrap(arg0);
|
|
3909
|
-
return ret;
|
|
3910
|
-
};
|
|
3911
|
-
imports.wbg.__wbg_instanceof_ArrayBuffer_e14585432e3737fc = function(arg0) {
|
|
3912
|
-
let result;
|
|
3913
|
-
try {
|
|
3914
|
-
result = arg0 instanceof ArrayBuffer;
|
|
3915
|
-
} catch (_) {
|
|
3916
|
-
result = false;
|
|
3917
|
-
}
|
|
3918
|
-
const ret = result;
|
|
3919
|
-
return ret;
|
|
3920
|
-
};
|
|
3921
|
-
imports.wbg.__wbg_instanceof_Response_f2cc20d9f7dfd644 = function(arg0) {
|
|
3922
|
-
let result;
|
|
3923
|
-
try {
|
|
3924
|
-
result = arg0 instanceof Response;
|
|
3925
|
-
} catch (_) {
|
|
3926
|
-
result = false;
|
|
3927
|
-
}
|
|
3928
|
-
const ret = result;
|
|
3929
|
-
return ret;
|
|
3930
|
-
};
|
|
3931
|
-
imports.wbg.__wbg_instanceof_Uint8Array_17156bcf118086a9 = function(arg0) {
|
|
3932
|
-
let result;
|
|
3933
|
-
try {
|
|
3934
|
-
result = arg0 instanceof Uint8Array;
|
|
3935
|
-
} catch (_) {
|
|
3936
|
-
result = false;
|
|
3937
|
-
}
|
|
3938
|
-
const ret = result;
|
|
3939
|
-
return ret;
|
|
3940
|
-
};
|
|
3941
|
-
imports.wbg.__wbg_isSafeInteger_343e2beeeece1bb0 = function(arg0) {
|
|
3942
|
-
const ret = Number.isSafeInteger(arg0);
|
|
3943
|
-
return ret;
|
|
3944
|
-
};
|
|
3945
|
-
imports.wbg.__wbg_iterator_9a24c88df860dc65 = function() {
|
|
3946
|
-
const ret = Symbol.iterator;
|
|
3947
|
-
return ret;
|
|
3948
|
-
};
|
|
3949
|
-
imports.wbg.__wbg_length_a446193dc22c12f8 = function(arg0) {
|
|
3950
|
-
const ret = arg0.length;
|
|
3951
|
-
return ret;
|
|
3952
|
-
};
|
|
3953
|
-
imports.wbg.__wbg_length_e2d2a49132c1b256 = function(arg0) {
|
|
3954
|
-
const ret = arg0.length;
|
|
3955
|
-
return ret;
|
|
3956
|
-
};
|
|
3957
|
-
imports.wbg.__wbg_mark_05056c522bddc362 = function() { return handleError(function (arg0, arg1, arg2) {
|
|
3958
|
-
arg0.mark(getStringFromWasm0(arg1, arg2));
|
|
3959
|
-
}, arguments) };
|
|
3960
|
-
imports.wbg.__wbg_mark_24a1a597f4f00679 = function() { return handleError(function (arg0, arg1, arg2, arg3) {
|
|
3961
|
-
arg0.mark(getStringFromWasm0(arg1, arg2), arg3);
|
|
3962
|
-
}, arguments) };
|
|
3963
|
-
imports.wbg.__wbg_measure_0b7379f5cfacac6d = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4, arg5, arg6) {
|
|
3964
|
-
arg0.measure(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4), getStringFromWasm0(arg5, arg6));
|
|
3965
|
-
}, arguments) };
|
|
3966
|
-
imports.wbg.__wbg_measure_7728846525e2cced = function() { return handleError(function (arg0, arg1, arg2, arg3) {
|
|
3967
|
-
arg0.measure(getStringFromWasm0(arg1, arg2), arg3);
|
|
3968
|
-
}, arguments) };
|
|
3969
|
-
imports.wbg.__wbg_message_new = function(arg0) {
|
|
3970
|
-
const ret = Message.__wrap(arg0);
|
|
3971
|
-
return ret;
|
|
3972
|
-
};
|
|
3973
|
-
imports.wbg.__wbg_msCrypto_0a36e2ec3a343d26 = function(arg0) {
|
|
3974
|
-
const ret = arg0.msCrypto;
|
|
3975
|
-
return ret;
|
|
3976
|
-
};
|
|
3977
|
-
imports.wbg.__wbg_new_018dcc2d6c8c2f6a = function() { return handleError(function () {
|
|
3978
|
-
const ret = new Headers();
|
|
3979
|
-
return ret;
|
|
3980
|
-
}, arguments) };
|
|
3981
|
-
imports.wbg.__wbg_new_23a2665fac83c611 = function(arg0, arg1) {
|
|
3982
|
-
try {
|
|
3983
|
-
var state0 = {a: arg0, b: arg1};
|
|
3984
|
-
var cb0 = (arg0, arg1) => {
|
|
3985
|
-
const a = state0.a;
|
|
3986
|
-
state0.a = 0;
|
|
3987
|
-
try {
|
|
3988
|
-
return __wbg_adapter_646(a, state0.b, arg0, arg1);
|
|
3989
|
-
} finally {
|
|
3990
|
-
state0.a = a;
|
|
3991
|
-
}
|
|
3992
|
-
};
|
|
3993
|
-
const ret = new Promise(cb0);
|
|
3994
|
-
return ret;
|
|
3995
|
-
} finally {
|
|
3996
|
-
state0.a = state0.b = 0;
|
|
3997
|
-
}
|
|
3998
|
-
};
|
|
3999
|
-
imports.wbg.__wbg_new_263e3ed0ecf4a0f0 = function() { return handleError(function (arg0) {
|
|
4000
|
-
const ret = new WebAssembly.Memory(arg0);
|
|
4001
|
-
return ret;
|
|
4002
|
-
}, arguments) };
|
|
4003
|
-
imports.wbg.__wbg_new_3c34f3fe365c1436 = function(arg0) {
|
|
4004
|
-
const ret = new SQLite(arg0);
|
|
4005
|
-
return ret;
|
|
4006
|
-
};
|
|
4007
|
-
imports.wbg.__wbg_new_405e22f390576ce2 = function() {
|
|
4008
|
-
const ret = new Object();
|
|
4009
|
-
return ret;
|
|
4010
|
-
};
|
|
4011
|
-
imports.wbg.__wbg_new_5e0be73521bc8c17 = function() {
|
|
4012
|
-
const ret = new Map();
|
|
4013
|
-
return ret;
|
|
4014
|
-
};
|
|
4015
|
-
imports.wbg.__wbg_new_78feb108b6472713 = function() {
|
|
4016
|
-
const ret = new Array();
|
|
4017
|
-
return ret;
|
|
4018
|
-
};
|
|
4019
|
-
imports.wbg.__wbg_new_8a6f238a6ece86ea = function() {
|
|
4020
|
-
const ret = new Error();
|
|
4021
|
-
return ret;
|
|
4022
|
-
};
|
|
4023
|
-
imports.wbg.__wbg_new_a12002a7f91c75be = function(arg0) {
|
|
4024
|
-
const ret = new Uint8Array(arg0);
|
|
4025
|
-
return ret;
|
|
4026
|
-
};
|
|
4027
|
-
imports.wbg.__wbg_new_c68d7209be747379 = function(arg0, arg1) {
|
|
4028
|
-
const ret = new Error(getStringFromWasm0(arg0, arg1));
|
|
4029
|
-
return ret;
|
|
4030
|
-
};
|
|
4031
|
-
imports.wbg.__wbg_new_e25e5aab09ff45db = function() { return handleError(function () {
|
|
4032
|
-
const ret = new AbortController();
|
|
4033
|
-
return ret;
|
|
4034
|
-
}, arguments) };
|
|
4035
|
-
imports.wbg.__wbg_newnoargs_105ed471475aaf50 = function(arg0, arg1) {
|
|
4036
|
-
const ret = new Function(getStringFromWasm0(arg0, arg1));
|
|
4037
|
-
return ret;
|
|
4038
|
-
};
|
|
4039
|
-
imports.wbg.__wbg_newwithbyteoffsetandlength_d97e637ebe145a9a = function(arg0, arg1, arg2) {
|
|
4040
|
-
const ret = new Uint8Array(arg0, arg1 >>> 0, arg2 >>> 0);
|
|
4041
|
-
return ret;
|
|
4042
|
-
};
|
|
4043
|
-
imports.wbg.__wbg_newwithlength_a381634e90c276d4 = function(arg0) {
|
|
4044
|
-
const ret = new Uint8Array(arg0 >>> 0);
|
|
4045
|
-
return ret;
|
|
4046
|
-
};
|
|
4047
|
-
imports.wbg.__wbg_newwithstrandinit_06c535e0a867c635 = function() { return handleError(function (arg0, arg1, arg2) {
|
|
4048
|
-
const ret = new Request(getStringFromWasm0(arg0, arg1), arg2);
|
|
4049
|
-
return ret;
|
|
4050
|
-
}, arguments) };
|
|
4051
|
-
imports.wbg.__wbg_next_25feadfc0913fea9 = function(arg0) {
|
|
4052
|
-
const ret = arg0.next;
|
|
4053
|
-
return ret;
|
|
4054
|
-
};
|
|
4055
|
-
imports.wbg.__wbg_next_6574e1a8a62d1055 = function() { return handleError(function (arg0) {
|
|
4056
|
-
const ret = arg0.next();
|
|
4057
|
-
return ret;
|
|
4058
|
-
}, arguments) };
|
|
4059
|
-
imports.wbg.__wbg_node_02999533c4ea02e3 = function(arg0) {
|
|
4060
|
-
const ret = arg0.node;
|
|
4061
|
-
return ret;
|
|
4062
|
-
};
|
|
4063
|
-
imports.wbg.__wbg_now_2c95c9de01293173 = function(arg0) {
|
|
4064
|
-
const ret = arg0.now();
|
|
4065
|
-
return ret;
|
|
4066
|
-
};
|
|
4067
|
-
imports.wbg.__wbg_now_807e54c39636c349 = function() {
|
|
4068
|
-
const ret = Date.now();
|
|
4069
|
-
return ret;
|
|
4070
|
-
};
|
|
4071
|
-
imports.wbg.__wbg_onconversation_43aee3fe67697518 = function(arg0, arg1) {
|
|
4072
|
-
arg0.on_conversation(Conversation.__wrap(arg1));
|
|
4073
|
-
};
|
|
4074
|
-
imports.wbg.__wbg_onerror_58742435b241fdbd = function(arg0, arg1) {
|
|
4075
|
-
arg0.on_error(arg1);
|
|
4076
|
-
};
|
|
4077
|
-
imports.wbg.__wbg_onmessage_12923aab4231469e = function(arg0, arg1) {
|
|
4078
|
-
arg0.on_message(Message.__wrap(arg1));
|
|
4079
|
-
};
|
|
4080
|
-
imports.wbg.__wbg_open_aba34ed1b3b52dc4 = function() { return handleError(function (arg0, arg1, arg2, arg3) {
|
|
4081
|
-
const ret = arg0.open(getStringFromWasm0(arg1, arg2), arg3 === 0x100000001 ? undefined : arg3);
|
|
4082
|
-
return ret;
|
|
4083
|
-
}, arguments) };
|
|
4084
|
-
imports.wbg.__wbg_peekPtr_6a7d4078b4e26f07 = function(arg0, arg1) {
|
|
4085
|
-
const ret = arg0.peekPtr(arg1);
|
|
4086
|
-
return ret;
|
|
4087
|
-
};
|
|
4088
|
-
imports.wbg.__wbg_performance_121b9855d716e029 = function() {
|
|
4089
|
-
const ret = globalThis.performance;
|
|
4090
|
-
return ret;
|
|
4091
|
-
};
|
|
4092
|
-
imports.wbg.__wbg_performance_7a3ffd0b17f663ad = function(arg0) {
|
|
4093
|
-
const ret = arg0.performance;
|
|
4094
|
-
return ret;
|
|
4095
|
-
};
|
|
4096
|
-
imports.wbg.__wbg_pointer_310208402223b1bb = function(arg0) {
|
|
4097
|
-
const ret = arg0.pointer;
|
|
4098
|
-
return ret;
|
|
4099
|
-
};
|
|
4100
|
-
imports.wbg.__wbg_preparev3_9322dce970cabecf = function(arg0, arg1, arg2, arg3, arg4, arg5, arg6) {
|
|
4101
|
-
const ret = arg0.prepare_v3(arg1, arg2 >>> 0, arg3, arg4 >>> 0, arg5, arg6);
|
|
4102
|
-
return ret;
|
|
4103
|
-
};
|
|
4104
|
-
imports.wbg.__wbg_process_5c1d670bc53614b8 = function(arg0) {
|
|
4105
|
-
const ret = arg0.process;
|
|
4106
|
-
return ret;
|
|
4107
|
-
};
|
|
4108
|
-
imports.wbg.__wbg_pstack_66a1730e634b3fee = function(arg0) {
|
|
4109
|
-
const ret = arg0.pstack;
|
|
4110
|
-
return ret;
|
|
4111
|
-
};
|
|
4112
|
-
imports.wbg.__wbg_push_737cfc8c1432c2c6 = function(arg0, arg1) {
|
|
4113
|
-
const ret = arg0.push(arg1);
|
|
4114
|
-
return ret;
|
|
4115
|
-
};
|
|
4116
|
-
imports.wbg.__wbg_queueMicrotask_97d92b4fcc8a61c5 = function(arg0) {
|
|
4117
|
-
queueMicrotask(arg0);
|
|
4118
|
-
};
|
|
4119
|
-
imports.wbg.__wbg_queueMicrotask_d3219def82552485 = function(arg0) {
|
|
4120
|
-
const ret = arg0.queueMicrotask;
|
|
4121
|
-
return ret;
|
|
4122
|
-
};
|
|
4123
|
-
imports.wbg.__wbg_randomFillSync_ab2cfe79ebbf2740 = function() { return handleError(function (arg0, arg1) {
|
|
4124
|
-
arg0.randomFillSync(arg1);
|
|
4125
|
-
}, arguments) };
|
|
4126
|
-
imports.wbg.__wbg_read_a2434af1186cb56c = function(arg0) {
|
|
4127
|
-
const ret = arg0.read();
|
|
4128
|
-
return ret;
|
|
4129
|
-
};
|
|
4130
|
-
imports.wbg.__wbg_registerdieselsqlfunctions_f374322dbb736b21 = function() { return handleError(function (arg0, arg1) {
|
|
4131
|
-
arg0.register_diesel_sql_functions(arg1);
|
|
4132
|
-
}, arguments) };
|
|
4133
|
-
imports.wbg.__wbg_releaseLock_091899af97991d2e = function(arg0) {
|
|
4134
|
-
arg0.releaseLock();
|
|
4135
|
-
};
|
|
4136
|
-
imports.wbg.__wbg_require_79b1e9274cde3c87 = function() { return handleError(function () {
|
|
4137
|
-
const ret = module.require;
|
|
4138
|
-
return ret;
|
|
4139
|
-
}, arguments) };
|
|
4140
|
-
imports.wbg.__wbg_reset_a6165093a081b112 = function(arg0, arg1) {
|
|
4141
|
-
const ret = arg0.reset(arg1);
|
|
4142
|
-
return ret;
|
|
4143
|
-
};
|
|
4144
|
-
imports.wbg.__wbg_resolve_4851785c9c5f573d = function(arg0) {
|
|
4145
|
-
const ret = Promise.resolve(arg0);
|
|
4146
|
-
return ret;
|
|
4147
|
-
};
|
|
4148
|
-
imports.wbg.__wbg_respond_1f279fa9f8edcb1c = function() { return handleError(function (arg0, arg1) {
|
|
4149
|
-
arg0.respond(arg1 >>> 0);
|
|
4150
|
-
}, arguments) };
|
|
4151
|
-
imports.wbg.__wbg_restore_43c154983844b05b = function(arg0, arg1) {
|
|
4152
|
-
arg0.restore(arg1);
|
|
4153
|
-
};
|
|
4154
|
-
imports.wbg.__wbg_setInterval_ed3b5e3c3ebb8a6d = function() { return handleError(function (arg0, arg1) {
|
|
4155
|
-
const ret = setInterval(arg0, arg1);
|
|
4156
|
-
return ret;
|
|
4157
|
-
}, arguments) };
|
|
4158
|
-
imports.wbg.__wbg_setTimeout_db2dbaeefb6f39c7 = function() { return handleError(function (arg0, arg1) {
|
|
4159
|
-
const ret = setTimeout(arg0, arg1);
|
|
4160
|
-
return ret;
|
|
4161
|
-
}, arguments) };
|
|
4162
|
-
imports.wbg.__wbg_set_37837023f3d740e8 = function(arg0, arg1, arg2) {
|
|
4163
|
-
arg0[arg1 >>> 0] = arg2;
|
|
4164
|
-
};
|
|
4165
|
-
imports.wbg.__wbg_set_3f1d0b984ed272ed = function(arg0, arg1, arg2) {
|
|
4166
|
-
arg0[arg1] = arg2;
|
|
4167
|
-
};
|
|
4168
|
-
imports.wbg.__wbg_set_65595bdd868b3009 = function(arg0, arg1, arg2) {
|
|
4169
|
-
arg0.set(arg1, arg2 >>> 0);
|
|
4170
|
-
};
|
|
4171
|
-
imports.wbg.__wbg_set_8fc6bf8a5b1071d1 = function(arg0, arg1, arg2) {
|
|
4172
|
-
const ret = arg0.set(arg1, arg2);
|
|
4173
|
-
return ret;
|
|
4174
|
-
};
|
|
4175
|
-
imports.wbg.__wbg_set_bb8cecf6a62b9f46 = function() { return handleError(function (arg0, arg1, arg2) {
|
|
4176
|
-
const ret = Reflect.set(arg0, arg1, arg2);
|
|
4177
|
-
return ret;
|
|
4178
|
-
}, arguments) };
|
|
4179
|
-
imports.wbg.__wbg_setbody_5923b78a95eedf29 = function(arg0, arg1) {
|
|
4180
|
-
arg0.body = arg1;
|
|
4181
|
-
};
|
|
4182
|
-
imports.wbg.__wbg_setcredentials_c3a22f1cd105a2c6 = function(arg0, arg1) {
|
|
4183
|
-
arg0.credentials = __wbindgen_enum_RequestCredentials[arg1];
|
|
4184
|
-
};
|
|
4185
|
-
imports.wbg.__wbg_setheaders_834c0bdb6a8949ad = function(arg0, arg1) {
|
|
4186
|
-
arg0.headers = arg1;
|
|
4187
|
-
};
|
|
4188
|
-
imports.wbg.__wbg_setmethod_3c5280fe5d890842 = function(arg0, arg1, arg2) {
|
|
4189
|
-
arg0.method = getStringFromWasm0(arg1, arg2);
|
|
4190
|
-
};
|
|
4191
|
-
imports.wbg.__wbg_setmode_5dc300b865044b65 = function(arg0, arg1) {
|
|
4192
|
-
arg0.mode = __wbindgen_enum_RequestMode[arg1];
|
|
4193
|
-
};
|
|
4194
|
-
imports.wbg.__wbg_setsignal_75b21ef3a81de905 = function(arg0, arg1) {
|
|
4195
|
-
arg0.signal = arg1;
|
|
4196
|
-
};
|
|
4197
|
-
imports.wbg.__wbg_signal_aaf9ad74119f20a4 = function(arg0) {
|
|
4198
|
-
const ret = arg0.signal;
|
|
4199
|
-
return ret;
|
|
4200
|
-
};
|
|
4201
|
-
imports.wbg.__wbg_sqlite3_0c56434abd1dc461 = function(arg0) {
|
|
4202
|
-
const ret = arg0.sqlite3;
|
|
4203
|
-
return ret;
|
|
4204
|
-
};
|
|
4205
|
-
imports.wbg.__wbg_stack_0ed75d68575b0f3c = function(arg0, arg1) {
|
|
4206
|
-
const ret = arg1.stack;
|
|
4207
|
-
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
4208
|
-
const len1 = WASM_VECTOR_LEN;
|
|
4209
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
4210
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
4211
|
-
};
|
|
4212
|
-
imports.wbg.__wbg_static_accessor_GLOBAL_88a902d13a557d07 = function() {
|
|
4213
|
-
const ret = typeof global === 'undefined' ? null : global;
|
|
4214
|
-
return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
|
|
4215
|
-
};
|
|
4216
|
-
imports.wbg.__wbg_static_accessor_GLOBAL_THIS_56578be7e9f832b0 = function() {
|
|
4217
|
-
const ret = typeof globalThis === 'undefined' ? null : globalThis;
|
|
4218
|
-
return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
|
|
4219
|
-
};
|
|
4220
|
-
imports.wbg.__wbg_static_accessor_SELF_37c5d418e4bf5819 = function() {
|
|
4221
|
-
const ret = typeof self === 'undefined' ? null : self;
|
|
4222
|
-
return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
|
|
4223
|
-
};
|
|
4224
|
-
imports.wbg.__wbg_static_accessor_WINDOW_5de37043a91a9c40 = function() {
|
|
4225
|
-
const ret = typeof window === 'undefined' ? null : window;
|
|
4226
|
-
return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
|
|
4227
|
-
};
|
|
4228
|
-
imports.wbg.__wbg_status_f6360336ca686bf0 = function(arg0) {
|
|
4229
|
-
const ret = arg0.status;
|
|
4230
|
-
return ret;
|
|
4231
|
-
};
|
|
4232
|
-
imports.wbg.__wbg_step_99a553e5d7fbed2f = function(arg0, arg1) {
|
|
4233
|
-
const ret = arg0.step(arg1);
|
|
4234
|
-
return ret;
|
|
4235
|
-
};
|
|
4236
|
-
imports.wbg.__wbg_stringify_f7ed6987935b4a24 = function() { return handleError(function (arg0) {
|
|
4237
|
-
const ret = JSON.stringify(arg0);
|
|
4238
|
-
return ret;
|
|
4239
|
-
}, arguments) };
|
|
4240
|
-
imports.wbg.__wbg_subarray_aa9065fa9dc5df96 = function(arg0, arg1, arg2) {
|
|
4241
|
-
const ret = arg0.subarray(arg1 >>> 0, arg2 >>> 0);
|
|
4242
|
-
return ret;
|
|
4243
|
-
};
|
|
4244
|
-
imports.wbg.__wbg_text_7805bea50de2af49 = function() { return handleError(function (arg0) {
|
|
4245
|
-
const ret = arg0.text();
|
|
4246
|
-
return ret;
|
|
4247
|
-
}, arguments) };
|
|
4248
|
-
imports.wbg.__wbg_then_44b73946d2fb3e7d = function(arg0, arg1) {
|
|
4249
|
-
const ret = arg0.then(arg1);
|
|
4250
|
-
return ret;
|
|
4251
|
-
};
|
|
4252
|
-
imports.wbg.__wbg_then_48b406749878a531 = function(arg0, arg1, arg2) {
|
|
4253
|
-
const ret = arg0.then(arg1, arg2);
|
|
4254
|
-
return ret;
|
|
4255
|
-
};
|
|
4256
|
-
imports.wbg.__wbg_url_ae10c34ca209681d = function(arg0, arg1) {
|
|
4257
|
-
const ret = arg1.url;
|
|
4258
|
-
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
4259
|
-
const len1 = WASM_VECTOR_LEN;
|
|
4260
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
4261
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
4262
|
-
};
|
|
4263
|
-
imports.wbg.__wbg_value_cd1ffa7b1ab794f1 = function(arg0) {
|
|
4264
|
-
const ret = arg0.value;
|
|
4265
|
-
return ret;
|
|
4266
|
-
};
|
|
4267
|
-
imports.wbg.__wbg_valueblob_b7834022c19ff288 = function(arg0, arg1) {
|
|
4268
|
-
const ret = arg0.value_blob(arg1 >>> 0);
|
|
4269
|
-
return ret;
|
|
4270
|
-
};
|
|
4271
|
-
imports.wbg.__wbg_valuebytes_c6924414a4f4b6f3 = function(arg0, arg1) {
|
|
4272
|
-
const ret = arg0.value_bytes(arg1 >>> 0);
|
|
4273
|
-
return ret;
|
|
4274
|
-
};
|
|
4275
|
-
imports.wbg.__wbg_valuedup_6d367159408d8196 = function(arg0, arg1) {
|
|
4276
|
-
const ret = arg0.value_dup(arg1 >>> 0);
|
|
4277
|
-
return ret;
|
|
4278
|
-
};
|
|
4279
|
-
imports.wbg.__wbg_valuefree_3f7442e9bb21e645 = function(arg0, arg1) {
|
|
4280
|
-
arg0.value_free(arg1 >>> 0);
|
|
4281
|
-
};
|
|
4282
|
-
imports.wbg.__wbg_valueint64_992b66e1610bc511 = function(arg0, arg1) {
|
|
4283
|
-
const ret = arg0.value_int64(arg1 >>> 0);
|
|
4284
|
-
return ret;
|
|
4285
|
-
};
|
|
4286
|
-
imports.wbg.__wbg_valueint_4d711af866e97d8e = function(arg0, arg1) {
|
|
4287
|
-
const ret = arg0.value_int(arg1 >>> 0);
|
|
4288
|
-
return ret;
|
|
4289
|
-
};
|
|
4290
|
-
imports.wbg.__wbg_valuetext_1305a3b91ca00e84 = function(arg0, arg1, arg2) {
|
|
4291
|
-
const ret = arg1.value_text(arg2 >>> 0);
|
|
4292
|
-
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
4293
|
-
const len1 = WASM_VECTOR_LEN;
|
|
4294
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
4295
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
4296
|
-
};
|
|
4297
|
-
imports.wbg.__wbg_valuetype_486feb6594cb75e3 = function(arg0, arg1) {
|
|
4298
|
-
const ret = arg0.value_type(arg1 >>> 0);
|
|
4299
|
-
return ret;
|
|
4300
|
-
};
|
|
4301
|
-
imports.wbg.__wbg_version_683c1e99c4c0439b = function(arg0) {
|
|
4302
|
-
const ret = arg0.version();
|
|
4303
|
-
return ret;
|
|
4304
|
-
};
|
|
4305
|
-
imports.wbg.__wbg_versions_c71aa1626a93e0a1 = function(arg0) {
|
|
4306
|
-
const ret = arg0.versions;
|
|
4307
|
-
return ret;
|
|
4308
|
-
};
|
|
4309
|
-
imports.wbg.__wbg_view_fd8a56e8983f448d = function(arg0) {
|
|
4310
|
-
const ret = arg0.view;
|
|
4311
|
-
return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
|
|
4312
|
-
};
|
|
4313
|
-
imports.wbg.__wbg_warn_4ca3906c248c47c4 = function(arg0) {
|
|
4314
|
-
console.warn(arg0);
|
|
4315
|
-
};
|
|
4316
|
-
imports.wbg.__wbg_warn_aaf1f4664a035bd6 = function(arg0, arg1, arg2, arg3) {
|
|
4317
|
-
console.warn(arg0, arg1, arg2, arg3);
|
|
4318
|
-
};
|
|
4319
|
-
imports.wbg.__wbg_wasm_a5f31e71db23f94b = function(arg0) {
|
|
4320
|
-
const ret = arg0.wasm;
|
|
4321
|
-
return ret;
|
|
4322
|
-
};
|
|
4323
|
-
imports.wbg.__wbindgen_array_new = function() {
|
|
4324
|
-
const ret = [];
|
|
4325
|
-
return ret;
|
|
4326
|
-
};
|
|
4327
|
-
imports.wbg.__wbindgen_array_push = function(arg0, arg1) {
|
|
4328
|
-
arg0.push(arg1);
|
|
4329
|
-
};
|
|
4330
|
-
imports.wbg.__wbindgen_as_number = function(arg0) {
|
|
4331
|
-
const ret = +arg0;
|
|
4332
|
-
return ret;
|
|
4333
|
-
};
|
|
4334
|
-
imports.wbg.__wbindgen_bigint_from_i64 = function(arg0) {
|
|
4335
|
-
const ret = arg0;
|
|
4336
|
-
return ret;
|
|
4337
|
-
};
|
|
4338
|
-
imports.wbg.__wbindgen_boolean_get = function(arg0) {
|
|
4339
|
-
const v = arg0;
|
|
4340
|
-
const ret = typeof(v) === 'boolean' ? (v ? 1 : 0) : 2;
|
|
4341
|
-
return ret;
|
|
4342
|
-
};
|
|
4343
|
-
imports.wbg.__wbindgen_cb_drop = function(arg0) {
|
|
4344
|
-
const obj = arg0.original;
|
|
4345
|
-
if (obj.cnt-- == 1) {
|
|
4346
|
-
obj.a = 0;
|
|
4347
|
-
return true;
|
|
4348
|
-
}
|
|
4349
|
-
const ret = false;
|
|
4350
|
-
return ret;
|
|
4351
|
-
};
|
|
4352
|
-
imports.wbg.__wbindgen_closure_wrapper14083 = function(arg0, arg1, arg2) {
|
|
4353
|
-
const ret = makeMutClosure(arg0, arg1, 2897, __wbg_adapter_52);
|
|
4354
|
-
return ret;
|
|
4355
|
-
};
|
|
4356
|
-
imports.wbg.__wbindgen_closure_wrapper14367 = function(arg0, arg1, arg2) {
|
|
4357
|
-
const ret = makeMutClosure(arg0, arg1, 2972, __wbg_adapter_55);
|
|
4358
|
-
return ret;
|
|
4359
|
-
};
|
|
4360
|
-
imports.wbg.__wbindgen_debug_string = function(arg0, arg1) {
|
|
4361
|
-
const ret = debugString(arg1);
|
|
4362
|
-
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
4363
|
-
const len1 = WASM_VECTOR_LEN;
|
|
4364
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
4365
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
4366
|
-
};
|
|
4367
|
-
imports.wbg.__wbindgen_error_new = function(arg0, arg1) {
|
|
4368
|
-
const ret = new Error(getStringFromWasm0(arg0, arg1));
|
|
4369
|
-
return ret;
|
|
4370
|
-
};
|
|
4371
|
-
imports.wbg.__wbindgen_in = function(arg0, arg1) {
|
|
4372
|
-
const ret = arg0 in arg1;
|
|
4373
|
-
return ret;
|
|
4374
|
-
};
|
|
4375
|
-
imports.wbg.__wbindgen_init_externref_table = function() {
|
|
4376
|
-
const table = wasm.__wbindgen_export_5;
|
|
4377
|
-
const offset = table.grow(4);
|
|
4378
|
-
table.set(0, undefined);
|
|
4379
|
-
table.set(offset + 0, undefined);
|
|
4380
|
-
table.set(offset + 1, null);
|
|
4381
|
-
table.set(offset + 2, true);
|
|
4382
|
-
table.set(offset + 3, false);
|
|
4383
|
-
;
|
|
4384
|
-
};
|
|
4385
|
-
imports.wbg.__wbindgen_is_function = function(arg0) {
|
|
4386
|
-
const ret = typeof(arg0) === 'function';
|
|
4387
|
-
return ret;
|
|
4388
|
-
};
|
|
4389
|
-
imports.wbg.__wbindgen_is_null = function(arg0) {
|
|
4390
|
-
const ret = arg0 === null;
|
|
4391
|
-
return ret;
|
|
4392
|
-
};
|
|
4393
|
-
imports.wbg.__wbindgen_is_object = function(arg0) {
|
|
4394
|
-
const val = arg0;
|
|
4395
|
-
const ret = typeof(val) === 'object' && val !== null;
|
|
4396
|
-
return ret;
|
|
4397
|
-
};
|
|
4398
|
-
imports.wbg.__wbindgen_is_string = function(arg0) {
|
|
4399
|
-
const ret = typeof(arg0) === 'string';
|
|
4400
|
-
return ret;
|
|
4401
|
-
};
|
|
4402
|
-
imports.wbg.__wbindgen_is_undefined = function(arg0) {
|
|
4403
|
-
const ret = arg0 === undefined;
|
|
4404
|
-
return ret;
|
|
4405
|
-
};
|
|
4406
|
-
imports.wbg.__wbindgen_jsval_loose_eq = function(arg0, arg1) {
|
|
4407
|
-
const ret = arg0 == arg1;
|
|
4408
|
-
return ret;
|
|
4409
|
-
};
|
|
4410
|
-
imports.wbg.__wbindgen_link_de369e9aa1a11bdd = function(arg0) {
|
|
4411
|
-
const ret = new URL('snippets/sqlite-web-90f8afa7b0cd2303/src/js/sqlite3-opfs-async-proxy.js', import.meta.url).toString();
|
|
4412
|
-
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
4413
|
-
const len1 = WASM_VECTOR_LEN;
|
|
4414
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
4415
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
4416
|
-
};
|
|
4417
|
-
imports.wbg.__wbindgen_memory = function() {
|
|
4418
|
-
const ret = wasm.memory;
|
|
4419
|
-
return ret;
|
|
4420
|
-
};
|
|
4421
|
-
imports.wbg.__wbindgen_number_get = function(arg0, arg1) {
|
|
4422
|
-
const obj = arg1;
|
|
4423
|
-
const ret = typeof(obj) === 'number' ? obj : undefined;
|
|
4424
|
-
getDataViewMemory0().setFloat64(arg0 + 8 * 1, isLikeNone(ret) ? 0 : ret, true);
|
|
4425
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 0, !isLikeNone(ret), true);
|
|
4426
|
-
};
|
|
4427
|
-
imports.wbg.__wbindgen_number_new = function(arg0) {
|
|
4428
|
-
const ret = arg0;
|
|
4429
|
-
return ret;
|
|
4430
|
-
};
|
|
4431
|
-
imports.wbg.__wbindgen_string_get = function(arg0, arg1) {
|
|
4432
|
-
const obj = arg1;
|
|
4433
|
-
const ret = typeof(obj) === 'string' ? obj : undefined;
|
|
4434
|
-
var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
4435
|
-
var len1 = WASM_VECTOR_LEN;
|
|
4436
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
4437
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
4438
|
-
};
|
|
4439
|
-
imports.wbg.__wbindgen_string_new = function(arg0, arg1) {
|
|
4440
|
-
const ret = getStringFromWasm0(arg0, arg1);
|
|
4441
|
-
return ret;
|
|
4442
|
-
};
|
|
4443
|
-
imports.wbg.__wbindgen_throw = function(arg0, arg1) {
|
|
4444
|
-
throw new Error(getStringFromWasm0(arg0, arg1));
|
|
4445
|
-
};
|
|
4446
|
-
imports.wbg.__wbindgen_try_into_number = function(arg0) {
|
|
4447
|
-
let result;
|
|
4448
|
-
try { result = +arg0 } catch (e) { result = e }
|
|
4449
|
-
const ret = result;
|
|
4450
|
-
return ret;
|
|
4451
|
-
};
|
|
4452
|
-
|
|
4453
|
-
return imports;
|
|
4454
|
-
}
|
|
4455
|
-
|
|
4456
|
-
function __wbg_init_memory(imports, memory) {
|
|
4457
|
-
|
|
4458
|
-
}
|
|
4459
|
-
|
|
4460
|
-
function __wbg_finalize_init(instance, module) {
|
|
4461
|
-
wasm = instance.exports;
|
|
4462
|
-
__wbg_init.__wbindgen_wasm_module = module;
|
|
4463
|
-
cachedDataViewMemory0 = null;
|
|
4464
|
-
cachedUint8ArrayMemory0 = null;
|
|
4465
|
-
|
|
4466
|
-
|
|
4467
|
-
wasm.__wbindgen_start();
|
|
4468
|
-
return wasm;
|
|
4469
|
-
}
|
|
4470
|
-
|
|
4471
|
-
function initSync(module) {
|
|
4472
|
-
if (wasm !== undefined) return wasm;
|
|
4473
|
-
|
|
4474
|
-
|
|
4475
|
-
if (typeof module !== 'undefined') {
|
|
4476
|
-
if (Object.getPrototypeOf(module) === Object.prototype) {
|
|
4477
|
-
({module} = module)
|
|
4478
|
-
} else {
|
|
4479
|
-
console.warn('using deprecated parameters for `initSync()`; pass a single object instead')
|
|
4480
|
-
}
|
|
4481
|
-
}
|
|
4482
|
-
|
|
4483
|
-
const imports = __wbg_get_imports();
|
|
4484
|
-
|
|
4485
|
-
__wbg_init_memory(imports);
|
|
4486
|
-
|
|
4487
|
-
if (!(module instanceof WebAssembly.Module)) {
|
|
4488
|
-
module = new WebAssembly.Module(module);
|
|
4489
|
-
}
|
|
4490
|
-
|
|
4491
|
-
const instance = new WebAssembly.Instance(module, imports);
|
|
4492
|
-
|
|
4493
|
-
return __wbg_finalize_init(instance, module);
|
|
4494
|
-
}
|
|
4495
|
-
|
|
4496
|
-
async function __wbg_init(module_or_path) {
|
|
4497
|
-
if (wasm !== undefined) return wasm;
|
|
4498
|
-
|
|
4499
|
-
|
|
4500
|
-
if (typeof module_or_path !== 'undefined') {
|
|
4501
|
-
if (Object.getPrototypeOf(module_or_path) === Object.prototype) {
|
|
4502
|
-
({module_or_path} = module_or_path)
|
|
4503
|
-
} else {
|
|
4504
|
-
console.warn('using deprecated parameters for the initialization function; pass a single object instead')
|
|
4505
|
-
}
|
|
4506
|
-
}
|
|
4507
|
-
|
|
4508
|
-
if (typeof module_or_path === 'undefined') {
|
|
4509
|
-
module_or_path = new URL('bindings_wasm_bg.wasm', import.meta.url);
|
|
4510
|
-
}
|
|
4511
|
-
const imports = __wbg_get_imports();
|
|
4512
|
-
|
|
4513
|
-
if (typeof module_or_path === 'string' || (typeof Request === 'function' && module_or_path instanceof Request) || (typeof URL === 'function' && module_or_path instanceof URL)) {
|
|
4514
|
-
module_or_path = fetch(module_or_path);
|
|
4515
|
-
}
|
|
4516
|
-
|
|
4517
|
-
__wbg_init_memory(imports);
|
|
4518
|
-
|
|
4519
|
-
const { instance, module } = await __wbg_load(await module_or_path, imports);
|
|
4520
|
-
|
|
4521
|
-
return __wbg_finalize_init(instance, module);
|
|
4522
|
-
}
|
|
4523
|
-
|
|
4524
|
-
export { initSync };
|
|
4525
|
-
export default __wbg_init;
|