@xmtp/wasm-bindings 0.0.13 → 0.0.14
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/dist/bindings_wasm.d.ts +186 -160
- package/dist/bindings_wasm.js +571 -617
- package/dist/bindings_wasm_bg.wasm +0 -0
- package/dist/bindings_wasm_bg.wasm.d.ts +131 -128
- package/package.json +2 -2
package/dist/bindings_wasm.js
CHANGED
|
@@ -76,6 +76,8 @@ function getDataViewMemory0() {
|
|
|
76
76
|
return cachedDataViewMemory0;
|
|
77
77
|
}
|
|
78
78
|
|
|
79
|
+
function getFromExternrefTable0(idx) { return wasm.__wbindgen_export_2.get(idx); }
|
|
80
|
+
|
|
79
81
|
const cachedTextDecoder = (typeof TextDecoder !== 'undefined' ? new TextDecoder('utf-8', { ignoreBOM: true, fatal: true }) : { decode: () => { throw Error('TextDecoder not available') } } );
|
|
80
82
|
|
|
81
83
|
if (typeof TextDecoder !== 'undefined') { cachedTextDecoder.decode(); };
|
|
@@ -85,9 +87,17 @@ function getStringFromWasm0(ptr, len) {
|
|
|
85
87
|
return cachedTextDecoder.decode(getUint8ArrayMemory0().subarray(ptr, ptr + len));
|
|
86
88
|
}
|
|
87
89
|
|
|
90
|
+
function getCachedStringFromWasm0(ptr, len) {
|
|
91
|
+
if (ptr === 0) {
|
|
92
|
+
return getFromExternrefTable0(len);
|
|
93
|
+
} else {
|
|
94
|
+
return getStringFromWasm0(ptr, len);
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
|
|
88
98
|
function addToExternrefTable0(obj) {
|
|
89
99
|
const idx = wasm.__externref_table_alloc();
|
|
90
|
-
wasm.
|
|
100
|
+
wasm.__wbindgen_export_2.set(idx, obj);
|
|
91
101
|
return idx;
|
|
92
102
|
}
|
|
93
103
|
|
|
@@ -200,45 +210,15 @@ function debugString(val) {
|
|
|
200
210
|
return className;
|
|
201
211
|
}
|
|
202
212
|
|
|
203
|
-
function
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
function _assertClass(instance, klass) {
|
|
210
|
-
if (!(instance instanceof klass)) {
|
|
211
|
-
throw new Error(`expected instance of ${klass.name}`);
|
|
212
|
-
}
|
|
213
|
-
}
|
|
214
|
-
/**
|
|
215
|
-
* @param {string} host
|
|
216
|
-
* @param {string} inbox_id
|
|
217
|
-
* @param {string} account_address
|
|
218
|
-
* @param {string | null} [db_path]
|
|
219
|
-
* @param {Uint8Array | null} [encryption_key]
|
|
220
|
-
* @param {string | null} [history_sync_url]
|
|
221
|
-
* @param {LogOptions | null} [log_options]
|
|
222
|
-
* @returns {Promise<Client>}
|
|
223
|
-
*/
|
|
224
|
-
export function createClient(host, inbox_id, account_address, db_path, encryption_key, history_sync_url, log_options) {
|
|
225
|
-
const ptr0 = passStringToWasm0(host, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
226
|
-
const len0 = WASM_VECTOR_LEN;
|
|
227
|
-
const ptr1 = passStringToWasm0(inbox_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
228
|
-
const len1 = WASM_VECTOR_LEN;
|
|
229
|
-
const ptr2 = passStringToWasm0(account_address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
230
|
-
const len2 = WASM_VECTOR_LEN;
|
|
231
|
-
var ptr3 = isLikeNone(db_path) ? 0 : passStringToWasm0(db_path, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
232
|
-
var len3 = WASM_VECTOR_LEN;
|
|
233
|
-
var ptr4 = isLikeNone(history_sync_url) ? 0 : passStringToWasm0(history_sync_url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
234
|
-
var len4 = WASM_VECTOR_LEN;
|
|
235
|
-
let ptr5 = 0;
|
|
236
|
-
if (!isLikeNone(log_options)) {
|
|
237
|
-
_assertClass(log_options, LogOptions);
|
|
238
|
-
ptr5 = log_options.__destroy_into_raw();
|
|
213
|
+
function getArrayJsValueFromWasm0(ptr, len) {
|
|
214
|
+
ptr = ptr >>> 0;
|
|
215
|
+
const mem = getDataViewMemory0();
|
|
216
|
+
const result = [];
|
|
217
|
+
for (let i = ptr; i < ptr + 4 * len; i += 4) {
|
|
218
|
+
result.push(wasm.__wbindgen_export_2.get(mem.getUint32(i, true)));
|
|
239
219
|
}
|
|
240
|
-
|
|
241
|
-
return
|
|
220
|
+
wasm.__externref_drop_slice(ptr, len);
|
|
221
|
+
return result;
|
|
242
222
|
}
|
|
243
223
|
|
|
244
224
|
function passArrayJsValueToWasm0(array, malloc) {
|
|
@@ -251,20 +231,33 @@ function passArrayJsValueToWasm0(array, malloc) {
|
|
|
251
231
|
return ptr;
|
|
252
232
|
}
|
|
253
233
|
|
|
254
|
-
function
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
const result = [];
|
|
258
|
-
for (let i = ptr; i < ptr + 4 * len; i += 4) {
|
|
259
|
-
result.push(wasm.__wbindgen_export_5.get(mem.getUint32(i, true)));
|
|
234
|
+
function _assertClass(instance, klass) {
|
|
235
|
+
if (!(instance instanceof klass)) {
|
|
236
|
+
throw new Error(`expected instance of ${klass.name}`);
|
|
260
237
|
}
|
|
261
|
-
|
|
262
|
-
|
|
238
|
+
}
|
|
239
|
+
|
|
240
|
+
function getArrayU8FromWasm0(ptr, len) {
|
|
241
|
+
ptr = ptr >>> 0;
|
|
242
|
+
return getUint8ArrayMemory0().subarray(ptr / 1, ptr / 1 + len);
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
function passArray8ToWasm0(arg, malloc) {
|
|
246
|
+
const ptr = malloc(arg.length * 1, 1) >>> 0;
|
|
247
|
+
getUint8ArrayMemory0().set(arg, ptr / 1);
|
|
248
|
+
WASM_VECTOR_LEN = arg.length;
|
|
249
|
+
return ptr;
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
function takeFromExternrefTable0(idx) {
|
|
253
|
+
const value = wasm.__wbindgen_export_2.get(idx);
|
|
254
|
+
wasm.__externref_table_dealloc(idx);
|
|
255
|
+
return value;
|
|
263
256
|
}
|
|
264
257
|
/**
|
|
265
258
|
* @param {string} host
|
|
266
259
|
* @param {string} account_address
|
|
267
|
-
* @returns {Promise<string
|
|
260
|
+
* @returns {Promise<string>}
|
|
268
261
|
*/
|
|
269
262
|
export function getInboxIdForAddress(host, account_address) {
|
|
270
263
|
const ptr0 = passStringToWasm0(host, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
@@ -280,24 +273,15 @@ export function getInboxIdForAddress(host, account_address) {
|
|
|
280
273
|
* @returns {string}
|
|
281
274
|
*/
|
|
282
275
|
export function generateInboxId(account_address) {
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
const ret = wasm.generateInboxId(ptr0, len0);
|
|
289
|
-
var ptr2 = ret[0];
|
|
290
|
-
var len2 = ret[1];
|
|
291
|
-
if (ret[3]) {
|
|
292
|
-
ptr2 = 0; len2 = 0;
|
|
293
|
-
throw takeFromExternrefTable0(ret[2]);
|
|
294
|
-
}
|
|
295
|
-
deferred3_0 = ptr2;
|
|
296
|
-
deferred3_1 = len2;
|
|
297
|
-
return getStringFromWasm0(ptr2, len2);
|
|
298
|
-
} finally {
|
|
299
|
-
wasm.__wbindgen_free(deferred3_0, deferred3_1, 1);
|
|
276
|
+
const ptr0 = passStringToWasm0(account_address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
277
|
+
const len0 = WASM_VECTOR_LEN;
|
|
278
|
+
const ret = wasm.generateInboxId(ptr0, len0);
|
|
279
|
+
if (ret[3]) {
|
|
280
|
+
throw takeFromExternrefTable0(ret[2]);
|
|
300
281
|
}
|
|
282
|
+
var v2 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
283
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
284
|
+
return v2;
|
|
301
285
|
}
|
|
302
286
|
|
|
303
287
|
/**
|
|
@@ -314,23 +298,42 @@ export function verifySignedWithPublicKey(signature_text, signature_bytes, publi
|
|
|
314
298
|
}
|
|
315
299
|
}
|
|
316
300
|
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
301
|
+
/**
|
|
302
|
+
* @param {string} host
|
|
303
|
+
* @param {string} inbox_id
|
|
304
|
+
* @param {string} account_address
|
|
305
|
+
* @param {string | null} [db_path]
|
|
306
|
+
* @param {Uint8Array | null} [encryption_key]
|
|
307
|
+
* @param {string | null} [history_sync_url]
|
|
308
|
+
* @param {LogOptions | null} [log_options]
|
|
309
|
+
* @returns {Promise<Client>}
|
|
310
|
+
*/
|
|
311
|
+
export function createClient(host, inbox_id, account_address, db_path, encryption_key, history_sync_url, log_options) {
|
|
312
|
+
const ptr0 = passStringToWasm0(host, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
313
|
+
const len0 = WASM_VECTOR_LEN;
|
|
314
|
+
const ptr1 = passStringToWasm0(inbox_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
315
|
+
const len1 = WASM_VECTOR_LEN;
|
|
316
|
+
const ptr2 = passStringToWasm0(account_address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
317
|
+
const len2 = WASM_VECTOR_LEN;
|
|
318
|
+
var ptr3 = isLikeNone(db_path) ? 0 : passStringToWasm0(db_path, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
319
|
+
var len3 = WASM_VECTOR_LEN;
|
|
320
|
+
var ptr4 = isLikeNone(history_sync_url) ? 0 : passStringToWasm0(history_sync_url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
321
|
+
var len4 = WASM_VECTOR_LEN;
|
|
322
|
+
let ptr5 = 0;
|
|
323
|
+
if (!isLikeNone(log_options)) {
|
|
324
|
+
_assertClass(log_options, LogOptions);
|
|
325
|
+
ptr5 = log_options.__destroy_into_raw();
|
|
326
|
+
}
|
|
327
|
+
const ret = wasm.createClient(ptr0, len0, ptr1, len1, ptr2, len2, ptr3, len3, isLikeNone(encryption_key) ? 0 : addToExternrefTable0(encryption_key), ptr4, len4, ptr5);
|
|
328
|
+
return ret;
|
|
320
329
|
}
|
|
321
330
|
|
|
322
|
-
function passArray8ToWasm0(arg, malloc) {
|
|
323
|
-
const ptr = malloc(arg.length * 1, 1) >>> 0;
|
|
324
|
-
getUint8ArrayMemory0().set(arg, ptr / 1);
|
|
325
|
-
WASM_VECTOR_LEN = arg.length;
|
|
326
|
-
return ptr;
|
|
327
|
-
}
|
|
328
331
|
function __wbg_adapter_52(arg0, arg1, arg2) {
|
|
329
|
-
wasm.
|
|
332
|
+
wasm.closure2900_externref_shim(arg0, arg1, arg2);
|
|
330
333
|
}
|
|
331
334
|
|
|
332
|
-
function
|
|
333
|
-
wasm.
|
|
335
|
+
function __wbg_adapter_612(arg0, arg1, arg2, arg3) {
|
|
336
|
+
wasm.closure3826_externref_shim(arg0, arg1, arg2, arg3);
|
|
334
337
|
}
|
|
335
338
|
|
|
336
339
|
/**
|
|
@@ -389,13 +392,14 @@ export const GroupPermissionsOptions = Object.freeze({
|
|
|
389
392
|
CustomPolicy: 2, "2": "CustomPolicy",
|
|
390
393
|
});
|
|
391
394
|
/**
|
|
392
|
-
* @enum {0 | 1 | 2 | 3}
|
|
395
|
+
* @enum {0 | 1 | 2 | 3 | 4}
|
|
393
396
|
*/
|
|
394
397
|
export const MetadataField = Object.freeze({
|
|
395
398
|
GroupName: 0, "0": "GroupName",
|
|
396
399
|
Description: 1, "1": "Description",
|
|
397
400
|
ImageUrlSquare: 2, "2": "ImageUrlSquare",
|
|
398
|
-
|
|
401
|
+
MessageExpirationFromMS: 3, "3": "MessageExpirationFromMS",
|
|
402
|
+
MessageExpirationMS: 4, "4": "MessageExpirationMS",
|
|
399
403
|
});
|
|
400
404
|
/**
|
|
401
405
|
* @enum {0 | 1 | 2}
|
|
@@ -476,113 +480,6 @@ export class Client {
|
|
|
476
480
|
const ptr = this.__destroy_into_raw();
|
|
477
481
|
wasm.__wbg_client_free(ptr, 0);
|
|
478
482
|
}
|
|
479
|
-
/**
|
|
480
|
-
* @returns {string}
|
|
481
|
-
*/
|
|
482
|
-
get accountAddress() {
|
|
483
|
-
let deferred1_0;
|
|
484
|
-
let deferred1_1;
|
|
485
|
-
try {
|
|
486
|
-
const ret = wasm.client_accountAddress(this.__wbg_ptr);
|
|
487
|
-
deferred1_0 = ret[0];
|
|
488
|
-
deferred1_1 = ret[1];
|
|
489
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
490
|
-
} finally {
|
|
491
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
492
|
-
}
|
|
493
|
-
}
|
|
494
|
-
/**
|
|
495
|
-
* @returns {string}
|
|
496
|
-
*/
|
|
497
|
-
get inboxId() {
|
|
498
|
-
let deferred1_0;
|
|
499
|
-
let deferred1_1;
|
|
500
|
-
try {
|
|
501
|
-
const ret = wasm.client_inboxId(this.__wbg_ptr);
|
|
502
|
-
deferred1_0 = ret[0];
|
|
503
|
-
deferred1_1 = ret[1];
|
|
504
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
505
|
-
} finally {
|
|
506
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
507
|
-
}
|
|
508
|
-
}
|
|
509
|
-
/**
|
|
510
|
-
* @returns {boolean}
|
|
511
|
-
*/
|
|
512
|
-
get isRegistered() {
|
|
513
|
-
const ret = wasm.client_isRegistered(this.__wbg_ptr);
|
|
514
|
-
return ret !== 0;
|
|
515
|
-
}
|
|
516
|
-
/**
|
|
517
|
-
* @returns {string}
|
|
518
|
-
*/
|
|
519
|
-
get installationId() {
|
|
520
|
-
let deferred1_0;
|
|
521
|
-
let deferred1_1;
|
|
522
|
-
try {
|
|
523
|
-
const ret = wasm.client_installationId(this.__wbg_ptr);
|
|
524
|
-
deferred1_0 = ret[0];
|
|
525
|
-
deferred1_1 = ret[1];
|
|
526
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
527
|
-
} finally {
|
|
528
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
529
|
-
}
|
|
530
|
-
}
|
|
531
|
-
/**
|
|
532
|
-
* @returns {Uint8Array}
|
|
533
|
-
*/
|
|
534
|
-
get installationIdBytes() {
|
|
535
|
-
const ret = wasm.client_installationIdBytes(this.__wbg_ptr);
|
|
536
|
-
return ret;
|
|
537
|
-
}
|
|
538
|
-
/**
|
|
539
|
-
* @param {string[]} account_addresses
|
|
540
|
-
* @returns {Promise<any>}
|
|
541
|
-
*/
|
|
542
|
-
canMessage(account_addresses) {
|
|
543
|
-
const ptr0 = passArrayJsValueToWasm0(account_addresses, wasm.__wbindgen_malloc);
|
|
544
|
-
const len0 = WASM_VECTOR_LEN;
|
|
545
|
-
const ret = wasm.client_canMessage(this.__wbg_ptr, ptr0, len0);
|
|
546
|
-
return ret;
|
|
547
|
-
}
|
|
548
|
-
/**
|
|
549
|
-
* @returns {Promise<void>}
|
|
550
|
-
*/
|
|
551
|
-
registerIdentity() {
|
|
552
|
-
const ret = wasm.client_registerIdentity(this.__wbg_ptr);
|
|
553
|
-
return ret;
|
|
554
|
-
}
|
|
555
|
-
/**
|
|
556
|
-
* @returns {Promise<void>}
|
|
557
|
-
*/
|
|
558
|
-
sendHistorySyncRequest() {
|
|
559
|
-
const ret = wasm.client_sendHistorySyncRequest(this.__wbg_ptr);
|
|
560
|
-
return ret;
|
|
561
|
-
}
|
|
562
|
-
/**
|
|
563
|
-
* @returns {Promise<void>}
|
|
564
|
-
*/
|
|
565
|
-
sendConsentSyncRequest() {
|
|
566
|
-
const ret = wasm.client_sendConsentSyncRequest(this.__wbg_ptr);
|
|
567
|
-
return ret;
|
|
568
|
-
}
|
|
569
|
-
/**
|
|
570
|
-
* @param {string} address
|
|
571
|
-
* @returns {Promise<string | undefined>}
|
|
572
|
-
*/
|
|
573
|
-
findInboxIdByAddress(address) {
|
|
574
|
-
const ptr0 = passStringToWasm0(address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
575
|
-
const len0 = WASM_VECTOR_LEN;
|
|
576
|
-
const ret = wasm.client_findInboxIdByAddress(this.__wbg_ptr, ptr0, len0);
|
|
577
|
-
return ret;
|
|
578
|
-
}
|
|
579
|
-
/**
|
|
580
|
-
* @returns {Conversations}
|
|
581
|
-
*/
|
|
582
|
-
conversations() {
|
|
583
|
-
const ret = wasm.client_conversations(this.__wbg_ptr);
|
|
584
|
-
return Conversations.__wrap(ret);
|
|
585
|
-
}
|
|
586
483
|
/**
|
|
587
484
|
* @param {Consent[]} records
|
|
588
485
|
* @returns {Promise<void>}
|
|
@@ -605,35 +502,16 @@ export class Client {
|
|
|
605
502
|
return ret;
|
|
606
503
|
}
|
|
607
504
|
/**
|
|
608
|
-
*
|
|
609
|
-
* * Get the client's inbox state.
|
|
610
|
-
* *
|
|
611
|
-
* * If `refresh_from_network` is true, the client will go to the network first to refresh the state.
|
|
612
|
-
* * Otherwise, the state will be read from the local database.
|
|
613
|
-
*
|
|
614
|
-
* @param {boolean} refresh_from_network
|
|
615
|
-
* @returns {Promise<InboxState>}
|
|
616
|
-
*/
|
|
617
|
-
inboxState(refresh_from_network) {
|
|
618
|
-
const ret = wasm.client_inboxState(this.__wbg_ptr, refresh_from_network);
|
|
619
|
-
return ret;
|
|
620
|
-
}
|
|
621
|
-
/**
|
|
622
|
-
* @param {string} inbox_id
|
|
623
|
-
* @returns {Promise<InboxState>}
|
|
624
|
-
*/
|
|
625
|
-
getLatestInboxState(inbox_id) {
|
|
626
|
-
const ptr0 = passStringToWasm0(inbox_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
627
|
-
const len0 = WASM_VECTOR_LEN;
|
|
628
|
-
const ret = wasm.client_getLatestInboxState(this.__wbg_ptr, ptr0, len0);
|
|
629
|
-
return ret;
|
|
630
|
-
}
|
|
631
|
-
/**
|
|
632
|
-
* @returns {Promise<string | undefined>}
|
|
505
|
+
* @returns {string}
|
|
633
506
|
*/
|
|
634
507
|
createInboxSignatureText() {
|
|
635
508
|
const ret = wasm.client_createInboxSignatureText(this.__wbg_ptr);
|
|
636
|
-
|
|
509
|
+
if (ret[3]) {
|
|
510
|
+
throw takeFromExternrefTable0(ret[2]);
|
|
511
|
+
}
|
|
512
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
513
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
514
|
+
return v1;
|
|
637
515
|
}
|
|
638
516
|
/**
|
|
639
517
|
* @param {string} new_wallet_address
|
|
@@ -724,6 +602,119 @@ export class Client {
|
|
|
724
602
|
throw takeFromExternrefTable0(ret[0]);
|
|
725
603
|
}
|
|
726
604
|
}
|
|
605
|
+
/**
|
|
606
|
+
* @returns {string}
|
|
607
|
+
*/
|
|
608
|
+
get accountAddress() {
|
|
609
|
+
const ret = wasm.client_accountAddress(this.__wbg_ptr);
|
|
610
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
611
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
612
|
+
return v1;
|
|
613
|
+
}
|
|
614
|
+
/**
|
|
615
|
+
* @returns {string}
|
|
616
|
+
*/
|
|
617
|
+
get inboxId() {
|
|
618
|
+
const ret = wasm.client_inboxId(this.__wbg_ptr);
|
|
619
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
620
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
621
|
+
return v1;
|
|
622
|
+
}
|
|
623
|
+
/**
|
|
624
|
+
* @returns {boolean}
|
|
625
|
+
*/
|
|
626
|
+
get isRegistered() {
|
|
627
|
+
const ret = wasm.client_isRegistered(this.__wbg_ptr);
|
|
628
|
+
return ret !== 0;
|
|
629
|
+
}
|
|
630
|
+
/**
|
|
631
|
+
* @returns {string}
|
|
632
|
+
*/
|
|
633
|
+
get installationId() {
|
|
634
|
+
const ret = wasm.client_installationId(this.__wbg_ptr);
|
|
635
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
636
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
637
|
+
return v1;
|
|
638
|
+
}
|
|
639
|
+
/**
|
|
640
|
+
* @returns {Uint8Array}
|
|
641
|
+
*/
|
|
642
|
+
get installationIdBytes() {
|
|
643
|
+
const ret = wasm.client_installationIdBytes(this.__wbg_ptr);
|
|
644
|
+
return ret;
|
|
645
|
+
}
|
|
646
|
+
/**
|
|
647
|
+
* @param {string[]} account_addresses
|
|
648
|
+
* @returns {Promise<any>}
|
|
649
|
+
*/
|
|
650
|
+
canMessage(account_addresses) {
|
|
651
|
+
const ptr0 = passArrayJsValueToWasm0(account_addresses, wasm.__wbindgen_malloc);
|
|
652
|
+
const len0 = WASM_VECTOR_LEN;
|
|
653
|
+
const ret = wasm.client_canMessage(this.__wbg_ptr, ptr0, len0);
|
|
654
|
+
return ret;
|
|
655
|
+
}
|
|
656
|
+
/**
|
|
657
|
+
* @returns {Promise<void>}
|
|
658
|
+
*/
|
|
659
|
+
registerIdentity() {
|
|
660
|
+
const ret = wasm.client_registerIdentity(this.__wbg_ptr);
|
|
661
|
+
return ret;
|
|
662
|
+
}
|
|
663
|
+
/**
|
|
664
|
+
* @returns {Promise<void>}
|
|
665
|
+
*/
|
|
666
|
+
sendHistorySyncRequest() {
|
|
667
|
+
const ret = wasm.client_sendHistorySyncRequest(this.__wbg_ptr);
|
|
668
|
+
return ret;
|
|
669
|
+
}
|
|
670
|
+
/**
|
|
671
|
+
* @returns {Promise<void>}
|
|
672
|
+
*/
|
|
673
|
+
sendConsentSyncRequest() {
|
|
674
|
+
const ret = wasm.client_sendConsentSyncRequest(this.__wbg_ptr);
|
|
675
|
+
return ret;
|
|
676
|
+
}
|
|
677
|
+
/**
|
|
678
|
+
* @param {string} address
|
|
679
|
+
* @returns {Promise<string>}
|
|
680
|
+
*/
|
|
681
|
+
findInboxIdByAddress(address) {
|
|
682
|
+
const ptr0 = passStringToWasm0(address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
683
|
+
const len0 = WASM_VECTOR_LEN;
|
|
684
|
+
const ret = wasm.client_findInboxIdByAddress(this.__wbg_ptr, ptr0, len0);
|
|
685
|
+
return ret;
|
|
686
|
+
}
|
|
687
|
+
/**
|
|
688
|
+
* @returns {Conversations}
|
|
689
|
+
*/
|
|
690
|
+
conversations() {
|
|
691
|
+
const ret = wasm.client_conversations(this.__wbg_ptr);
|
|
692
|
+
return Conversations.__wrap(ret);
|
|
693
|
+
}
|
|
694
|
+
/**
|
|
695
|
+
*
|
|
696
|
+
* * Get the client's inbox state.
|
|
697
|
+
* *
|
|
698
|
+
* * If `refresh_from_network` is true, the client will go to the network first to refresh the state.
|
|
699
|
+
* * Otherwise, the state will be read from the local database.
|
|
700
|
+
*
|
|
701
|
+
* @param {boolean} refresh_from_network
|
|
702
|
+
* @returns {Promise<InboxState>}
|
|
703
|
+
*/
|
|
704
|
+
inboxState(refresh_from_network) {
|
|
705
|
+
const ret = wasm.client_inboxState(this.__wbg_ptr, refresh_from_network);
|
|
706
|
+
return ret;
|
|
707
|
+
}
|
|
708
|
+
/**
|
|
709
|
+
* @param {string} inbox_id
|
|
710
|
+
* @returns {Promise<InboxState>}
|
|
711
|
+
*/
|
|
712
|
+
getLatestInboxState(inbox_id) {
|
|
713
|
+
const ptr0 = passStringToWasm0(inbox_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
714
|
+
const len0 = WASM_VECTOR_LEN;
|
|
715
|
+
const ret = wasm.client_getLatestInboxState(this.__wbg_ptr, ptr0, len0);
|
|
716
|
+
return ret;
|
|
717
|
+
}
|
|
727
718
|
}
|
|
728
719
|
|
|
729
720
|
const ConsentFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
@@ -780,16 +771,10 @@ export class Consent {
|
|
|
780
771
|
* @returns {string}
|
|
781
772
|
*/
|
|
782
773
|
get entity() {
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
deferred1_0 = ret[0];
|
|
788
|
-
deferred1_1 = ret[1];
|
|
789
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
790
|
-
} finally {
|
|
791
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
792
|
-
}
|
|
774
|
+
const ret = wasm.__wbg_get_consent_entity(this.__wbg_ptr);
|
|
775
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
776
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
777
|
+
return v1;
|
|
793
778
|
}
|
|
794
779
|
/**
|
|
795
780
|
* @param {string} arg0
|
|
@@ -843,16 +828,10 @@ export class ContentTypeId {
|
|
|
843
828
|
* @returns {string}
|
|
844
829
|
*/
|
|
845
830
|
get authorityId() {
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
deferred1_0 = ret[0];
|
|
851
|
-
deferred1_1 = ret[1];
|
|
852
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
853
|
-
} finally {
|
|
854
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
855
|
-
}
|
|
831
|
+
const ret = wasm.__wbg_get_contenttypeid_authorityId(this.__wbg_ptr);
|
|
832
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
833
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
834
|
+
return v1;
|
|
856
835
|
}
|
|
857
836
|
/**
|
|
858
837
|
* @param {string} arg0
|
|
@@ -866,16 +845,10 @@ export class ContentTypeId {
|
|
|
866
845
|
* @returns {string}
|
|
867
846
|
*/
|
|
868
847
|
get typeId() {
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
deferred1_0 = ret[0];
|
|
874
|
-
deferred1_1 = ret[1];
|
|
875
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
876
|
-
} finally {
|
|
877
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
878
|
-
}
|
|
848
|
+
const ret = wasm.__wbg_get_contenttypeid_typeId(this.__wbg_ptr);
|
|
849
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
850
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
851
|
+
return v1;
|
|
879
852
|
}
|
|
880
853
|
/**
|
|
881
854
|
* @param {string} arg0
|
|
@@ -977,16 +950,10 @@ export class Conversation {
|
|
|
977
950
|
* @returns {string}
|
|
978
951
|
*/
|
|
979
952
|
id() {
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
|
|
983
|
-
|
|
984
|
-
deferred1_0 = ret[0];
|
|
985
|
-
deferred1_1 = ret[1];
|
|
986
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
987
|
-
} finally {
|
|
988
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
989
|
-
}
|
|
953
|
+
const ret = wasm.conversation_id(this.__wbg_ptr);
|
|
954
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
955
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
956
|
+
return v1;
|
|
990
957
|
}
|
|
991
958
|
/**
|
|
992
959
|
* @param {EncodedContent} encoded_content
|
|
@@ -1004,24 +971,15 @@ export class Conversation {
|
|
|
1004
971
|
* @returns {string}
|
|
1005
972
|
*/
|
|
1006
973
|
sendOptimistic(encoded_content) {
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
const ret = wasm.conversation_sendOptimistic(this.__wbg_ptr, ptr0);
|
|
1013
|
-
var ptr2 = ret[0];
|
|
1014
|
-
var len2 = ret[1];
|
|
1015
|
-
if (ret[3]) {
|
|
1016
|
-
ptr2 = 0; len2 = 0;
|
|
1017
|
-
throw takeFromExternrefTable0(ret[2]);
|
|
1018
|
-
}
|
|
1019
|
-
deferred3_0 = ptr2;
|
|
1020
|
-
deferred3_1 = len2;
|
|
1021
|
-
return getStringFromWasm0(ptr2, len2);
|
|
1022
|
-
} finally {
|
|
1023
|
-
wasm.__wbindgen_free(deferred3_0, deferred3_1, 1);
|
|
974
|
+
_assertClass(encoded_content, EncodedContent);
|
|
975
|
+
var ptr0 = encoded_content.__destroy_into_raw();
|
|
976
|
+
const ret = wasm.conversation_sendOptimistic(this.__wbg_ptr, ptr0);
|
|
977
|
+
if (ret[3]) {
|
|
978
|
+
throw takeFromExternrefTable0(ret[2]);
|
|
1024
979
|
}
|
|
980
|
+
var v2 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
981
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
982
|
+
return v2;
|
|
1025
983
|
}
|
|
1026
984
|
/**
|
|
1027
985
|
* Publish all unpublished messages
|
|
@@ -1212,22 +1170,13 @@ export class Conversation {
|
|
|
1212
1170
|
* @returns {string}
|
|
1213
1171
|
*/
|
|
1214
1172
|
groupName() {
|
|
1215
|
-
|
|
1216
|
-
|
|
1217
|
-
|
|
1218
|
-
const ret = wasm.conversation_groupName(this.__wbg_ptr);
|
|
1219
|
-
var ptr1 = ret[0];
|
|
1220
|
-
var len1 = ret[1];
|
|
1221
|
-
if (ret[3]) {
|
|
1222
|
-
ptr1 = 0; len1 = 0;
|
|
1223
|
-
throw takeFromExternrefTable0(ret[2]);
|
|
1224
|
-
}
|
|
1225
|
-
deferred2_0 = ptr1;
|
|
1226
|
-
deferred2_1 = len1;
|
|
1227
|
-
return getStringFromWasm0(ptr1, len1);
|
|
1228
|
-
} finally {
|
|
1229
|
-
wasm.__wbindgen_free(deferred2_0, deferred2_1, 1);
|
|
1173
|
+
const ret = wasm.conversation_groupName(this.__wbg_ptr);
|
|
1174
|
+
if (ret[3]) {
|
|
1175
|
+
throw takeFromExternrefTable0(ret[2]);
|
|
1230
1176
|
}
|
|
1177
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
1178
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
1179
|
+
return v1;
|
|
1231
1180
|
}
|
|
1232
1181
|
/**
|
|
1233
1182
|
* @param {string} group_image_url_square
|
|
@@ -1242,23 +1191,14 @@ export class Conversation {
|
|
|
1242
1191
|
/**
|
|
1243
1192
|
* @returns {string}
|
|
1244
1193
|
*/
|
|
1245
|
-
groupImageUrlSquare() {
|
|
1246
|
-
|
|
1247
|
-
|
|
1248
|
-
|
|
1249
|
-
const ret = wasm.conversation_groupImageUrlSquare(this.__wbg_ptr);
|
|
1250
|
-
var ptr1 = ret[0];
|
|
1251
|
-
var len1 = ret[1];
|
|
1252
|
-
if (ret[3]) {
|
|
1253
|
-
ptr1 = 0; len1 = 0;
|
|
1254
|
-
throw takeFromExternrefTable0(ret[2]);
|
|
1255
|
-
}
|
|
1256
|
-
deferred2_0 = ptr1;
|
|
1257
|
-
deferred2_1 = len1;
|
|
1258
|
-
return getStringFromWasm0(ptr1, len1);
|
|
1259
|
-
} finally {
|
|
1260
|
-
wasm.__wbindgen_free(deferred2_0, deferred2_1, 1);
|
|
1194
|
+
groupImageUrlSquare() {
|
|
1195
|
+
const ret = wasm.conversation_groupImageUrlSquare(this.__wbg_ptr);
|
|
1196
|
+
if (ret[3]) {
|
|
1197
|
+
throw takeFromExternrefTable0(ret[2]);
|
|
1261
1198
|
}
|
|
1199
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
1200
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
1201
|
+
return v1;
|
|
1262
1202
|
}
|
|
1263
1203
|
/**
|
|
1264
1204
|
* @param {string} group_description
|
|
@@ -1274,53 +1214,24 @@ export class Conversation {
|
|
|
1274
1214
|
* @returns {string}
|
|
1275
1215
|
*/
|
|
1276
1216
|
groupDescription() {
|
|
1277
|
-
|
|
1278
|
-
|
|
1279
|
-
|
|
1280
|
-
const ret = wasm.conversation_groupDescription(this.__wbg_ptr);
|
|
1281
|
-
var ptr1 = ret[0];
|
|
1282
|
-
var len1 = ret[1];
|
|
1283
|
-
if (ret[3]) {
|
|
1284
|
-
ptr1 = 0; len1 = 0;
|
|
1285
|
-
throw takeFromExternrefTable0(ret[2]);
|
|
1286
|
-
}
|
|
1287
|
-
deferred2_0 = ptr1;
|
|
1288
|
-
deferred2_1 = len1;
|
|
1289
|
-
return getStringFromWasm0(ptr1, len1);
|
|
1290
|
-
} finally {
|
|
1291
|
-
wasm.__wbindgen_free(deferred2_0, deferred2_1, 1);
|
|
1217
|
+
const ret = wasm.conversation_groupDescription(this.__wbg_ptr);
|
|
1218
|
+
if (ret[3]) {
|
|
1219
|
+
throw takeFromExternrefTable0(ret[2]);
|
|
1292
1220
|
}
|
|
1221
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
1222
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
1223
|
+
return v1;
|
|
1293
1224
|
}
|
|
1294
1225
|
/**
|
|
1295
|
-
* @param {
|
|
1296
|
-
* @returns {
|
|
1297
|
-
*/
|
|
1298
|
-
updateGroupPinnedFrameUrl(pinned_frame_url) {
|
|
1299
|
-
const ptr0 = passStringToWasm0(pinned_frame_url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1300
|
-
const len0 = WASM_VECTOR_LEN;
|
|
1301
|
-
const ret = wasm.conversation_updateGroupPinnedFrameUrl(this.__wbg_ptr, ptr0, len0);
|
|
1302
|
-
return ret;
|
|
1303
|
-
}
|
|
1304
|
-
/**
|
|
1305
|
-
* @returns {string}
|
|
1226
|
+
* @param {any} callback
|
|
1227
|
+
* @returns {StreamCloser}
|
|
1306
1228
|
*/
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1311
|
-
const ret = wasm.conversation_groupPinnedFrameUrl(this.__wbg_ptr);
|
|
1312
|
-
var ptr1 = ret[0];
|
|
1313
|
-
var len1 = ret[1];
|
|
1314
|
-
if (ret[3]) {
|
|
1315
|
-
ptr1 = 0; len1 = 0;
|
|
1316
|
-
throw takeFromExternrefTable0(ret[2]);
|
|
1317
|
-
}
|
|
1318
|
-
deferred2_0 = ptr1;
|
|
1319
|
-
deferred2_1 = len1;
|
|
1320
|
-
return getStringFromWasm0(ptr1, len1);
|
|
1321
|
-
} finally {
|
|
1322
|
-
wasm.__wbindgen_free(deferred2_0, deferred2_1, 1);
|
|
1229
|
+
stream(callback) {
|
|
1230
|
+
const ret = wasm.conversation_stream(this.__wbg_ptr, callback);
|
|
1231
|
+
if (ret[2]) {
|
|
1232
|
+
throw takeFromExternrefTable0(ret[1]);
|
|
1323
1233
|
}
|
|
1234
|
+
return StreamCloser.__wrap(ret[0]);
|
|
1324
1235
|
}
|
|
1325
1236
|
/**
|
|
1326
1237
|
* @returns {bigint}
|
|
@@ -1343,22 +1254,13 @@ export class Conversation {
|
|
|
1343
1254
|
* @returns {string}
|
|
1344
1255
|
*/
|
|
1345
1256
|
addedByInboxId() {
|
|
1346
|
-
|
|
1347
|
-
|
|
1348
|
-
|
|
1349
|
-
const ret = wasm.conversation_addedByInboxId(this.__wbg_ptr);
|
|
1350
|
-
var ptr1 = ret[0];
|
|
1351
|
-
var len1 = ret[1];
|
|
1352
|
-
if (ret[3]) {
|
|
1353
|
-
ptr1 = 0; len1 = 0;
|
|
1354
|
-
throw takeFromExternrefTable0(ret[2]);
|
|
1355
|
-
}
|
|
1356
|
-
deferred2_0 = ptr1;
|
|
1357
|
-
deferred2_1 = len1;
|
|
1358
|
-
return getStringFromWasm0(ptr1, len1);
|
|
1359
|
-
} finally {
|
|
1360
|
-
wasm.__wbindgen_free(deferred2_0, deferred2_1, 1);
|
|
1257
|
+
const ret = wasm.conversation_addedByInboxId(this.__wbg_ptr);
|
|
1258
|
+
if (ret[3]) {
|
|
1259
|
+
throw takeFromExternrefTable0(ret[2]);
|
|
1361
1260
|
}
|
|
1261
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
1262
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
1263
|
+
return v1;
|
|
1362
1264
|
}
|
|
1363
1265
|
/**
|
|
1364
1266
|
* @returns {Promise<GroupMetadata>}
|
|
@@ -1371,22 +1273,13 @@ export class Conversation {
|
|
|
1371
1273
|
* @returns {string}
|
|
1372
1274
|
*/
|
|
1373
1275
|
dmPeerInboxId() {
|
|
1374
|
-
|
|
1375
|
-
|
|
1376
|
-
|
|
1377
|
-
const ret = wasm.conversation_dmPeerInboxId(this.__wbg_ptr);
|
|
1378
|
-
var ptr1 = ret[0];
|
|
1379
|
-
var len1 = ret[1];
|
|
1380
|
-
if (ret[3]) {
|
|
1381
|
-
ptr1 = 0; len1 = 0;
|
|
1382
|
-
throw takeFromExternrefTable0(ret[2]);
|
|
1383
|
-
}
|
|
1384
|
-
deferred2_0 = ptr1;
|
|
1385
|
-
deferred2_1 = len1;
|
|
1386
|
-
return getStringFromWasm0(ptr1, len1);
|
|
1387
|
-
} finally {
|
|
1388
|
-
wasm.__wbindgen_free(deferred2_0, deferred2_1, 1);
|
|
1276
|
+
const ret = wasm.conversation_dmPeerInboxId(this.__wbg_ptr);
|
|
1277
|
+
if (ret[3]) {
|
|
1278
|
+
throw takeFromExternrefTable0(ret[2]);
|
|
1389
1279
|
}
|
|
1280
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
1281
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
1282
|
+
return v1;
|
|
1390
1283
|
}
|
|
1391
1284
|
/**
|
|
1392
1285
|
* @param {PermissionUpdateType} permission_update_type
|
|
@@ -1395,7 +1288,7 @@ export class Conversation {
|
|
|
1395
1288
|
* @returns {Promise<void>}
|
|
1396
1289
|
*/
|
|
1397
1290
|
updatePermissionPolicy(permission_update_type, permission_policy_option, metadata_field) {
|
|
1398
|
-
const ret = wasm.conversation_updatePermissionPolicy(this.__wbg_ptr, permission_update_type, permission_policy_option, isLikeNone(metadata_field) ?
|
|
1291
|
+
const ret = wasm.conversation_updatePermissionPolicy(this.__wbg_ptr, permission_update_type, permission_policy_option, isLikeNone(metadata_field) ? 5 : metadata_field);
|
|
1399
1292
|
return ret;
|
|
1400
1293
|
}
|
|
1401
1294
|
}
|
|
@@ -1562,6 +1455,52 @@ export class Conversations {
|
|
|
1562
1455
|
}
|
|
1563
1456
|
return takeFromExternrefTable0(ret[0]);
|
|
1564
1457
|
}
|
|
1458
|
+
/**
|
|
1459
|
+
* @param {any} callback
|
|
1460
|
+
* @param {ConversationType | null} [conversation_type]
|
|
1461
|
+
* @returns {StreamCloser}
|
|
1462
|
+
*/
|
|
1463
|
+
stream(callback, conversation_type) {
|
|
1464
|
+
const ret = wasm.conversations_stream(this.__wbg_ptr, callback, isLikeNone(conversation_type) ? 3 : conversation_type);
|
|
1465
|
+
if (ret[2]) {
|
|
1466
|
+
throw takeFromExternrefTable0(ret[1]);
|
|
1467
|
+
}
|
|
1468
|
+
return StreamCloser.__wrap(ret[0]);
|
|
1469
|
+
}
|
|
1470
|
+
/**
|
|
1471
|
+
* @param {any} callback
|
|
1472
|
+
* @returns {StreamCloser}
|
|
1473
|
+
*/
|
|
1474
|
+
streamGroups(callback) {
|
|
1475
|
+
const ret = wasm.conversations_streamGroups(this.__wbg_ptr, callback);
|
|
1476
|
+
if (ret[2]) {
|
|
1477
|
+
throw takeFromExternrefTable0(ret[1]);
|
|
1478
|
+
}
|
|
1479
|
+
return StreamCloser.__wrap(ret[0]);
|
|
1480
|
+
}
|
|
1481
|
+
/**
|
|
1482
|
+
* @param {any} callback
|
|
1483
|
+
* @returns {StreamCloser}
|
|
1484
|
+
*/
|
|
1485
|
+
streamDms(callback) {
|
|
1486
|
+
const ret = wasm.conversations_streamDms(this.__wbg_ptr, callback);
|
|
1487
|
+
if (ret[2]) {
|
|
1488
|
+
throw takeFromExternrefTable0(ret[1]);
|
|
1489
|
+
}
|
|
1490
|
+
return StreamCloser.__wrap(ret[0]);
|
|
1491
|
+
}
|
|
1492
|
+
/**
|
|
1493
|
+
* @param {any} callback
|
|
1494
|
+
* @param {ConversationType | null} [conversation_type]
|
|
1495
|
+
* @returns {StreamCloser}
|
|
1496
|
+
*/
|
|
1497
|
+
streamAllMessages(callback, conversation_type) {
|
|
1498
|
+
const ret = wasm.conversations_streamAllMessages(this.__wbg_ptr, callback, isLikeNone(conversation_type) ? 3 : conversation_type);
|
|
1499
|
+
if (ret[2]) {
|
|
1500
|
+
throw takeFromExternrefTable0(ret[1]);
|
|
1501
|
+
}
|
|
1502
|
+
return StreamCloser.__wrap(ret[0]);
|
|
1503
|
+
}
|
|
1565
1504
|
}
|
|
1566
1505
|
|
|
1567
1506
|
const CreateGroupOptionsFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
@@ -1595,15 +1534,12 @@ export class CreateGroupOptions {
|
|
|
1595
1534
|
wasm.__wbg_set_creategroupoptions_permissions(this.__wbg_ptr, isLikeNone(arg0) ? 3 : arg0);
|
|
1596
1535
|
}
|
|
1597
1536
|
/**
|
|
1598
|
-
* @returns {string
|
|
1537
|
+
* @returns {string}
|
|
1599
1538
|
*/
|
|
1600
1539
|
get groupName() {
|
|
1601
1540
|
const ret = wasm.__wbg_get_creategroupoptions_groupName(this.__wbg_ptr);
|
|
1602
|
-
|
|
1603
|
-
if (ret[0] !== 0) {
|
|
1604
|
-
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
1605
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
1606
|
-
}
|
|
1541
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
1542
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
1607
1543
|
return v1;
|
|
1608
1544
|
}
|
|
1609
1545
|
/**
|
|
@@ -1615,15 +1551,12 @@ export class CreateGroupOptions {
|
|
|
1615
1551
|
wasm.__wbg_set_creategroupoptions_groupName(this.__wbg_ptr, ptr0, len0);
|
|
1616
1552
|
}
|
|
1617
1553
|
/**
|
|
1618
|
-
* @returns {string
|
|
1554
|
+
* @returns {string}
|
|
1619
1555
|
*/
|
|
1620
1556
|
get groupImageUrlSquare() {
|
|
1621
1557
|
const ret = wasm.__wbg_get_creategroupoptions_groupImageUrlSquare(this.__wbg_ptr);
|
|
1622
|
-
|
|
1623
|
-
if (ret[0] !== 0) {
|
|
1624
|
-
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
1625
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
1626
|
-
}
|
|
1558
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
1559
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
1627
1560
|
return v1;
|
|
1628
1561
|
}
|
|
1629
1562
|
/**
|
|
@@ -1635,15 +1568,12 @@ export class CreateGroupOptions {
|
|
|
1635
1568
|
wasm.__wbg_set_creategroupoptions_groupImageUrlSquare(this.__wbg_ptr, ptr0, len0);
|
|
1636
1569
|
}
|
|
1637
1570
|
/**
|
|
1638
|
-
* @returns {string
|
|
1571
|
+
* @returns {string}
|
|
1639
1572
|
*/
|
|
1640
1573
|
get groupDescription() {
|
|
1641
1574
|
const ret = wasm.__wbg_get_creategroupoptions_groupDescription(this.__wbg_ptr);
|
|
1642
|
-
|
|
1643
|
-
if (ret[0] !== 0) {
|
|
1644
|
-
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
1645
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
1646
|
-
}
|
|
1575
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
1576
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
1647
1577
|
return v1;
|
|
1648
1578
|
}
|
|
1649
1579
|
/**
|
|
@@ -1654,26 +1584,6 @@ export class CreateGroupOptions {
|
|
|
1654
1584
|
var len0 = WASM_VECTOR_LEN;
|
|
1655
1585
|
wasm.__wbg_set_creategroupoptions_groupDescription(this.__wbg_ptr, ptr0, len0);
|
|
1656
1586
|
}
|
|
1657
|
-
/**
|
|
1658
|
-
* @returns {string | undefined}
|
|
1659
|
-
*/
|
|
1660
|
-
get groupPinnedFrameUrl() {
|
|
1661
|
-
const ret = wasm.__wbg_get_creategroupoptions_groupPinnedFrameUrl(this.__wbg_ptr);
|
|
1662
|
-
let v1;
|
|
1663
|
-
if (ret[0] !== 0) {
|
|
1664
|
-
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
1665
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
1666
|
-
}
|
|
1667
|
-
return v1;
|
|
1668
|
-
}
|
|
1669
|
-
/**
|
|
1670
|
-
* @param {string | null} [arg0]
|
|
1671
|
-
*/
|
|
1672
|
-
set groupPinnedFrameUrl(arg0) {
|
|
1673
|
-
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1674
|
-
var len0 = WASM_VECTOR_LEN;
|
|
1675
|
-
wasm.__wbg_set_creategroupoptions_groupPinnedFrameUrl(this.__wbg_ptr, ptr0, len0);
|
|
1676
|
-
}
|
|
1677
1587
|
/**
|
|
1678
1588
|
* @returns {PermissionPolicySet | undefined}
|
|
1679
1589
|
*/
|
|
@@ -1693,56 +1603,49 @@ export class CreateGroupOptions {
|
|
|
1693
1603
|
wasm.__wbg_set_creategroupoptions_customPermissionPolicySet(this.__wbg_ptr, ptr0);
|
|
1694
1604
|
}
|
|
1695
1605
|
/**
|
|
1696
|
-
* @returns {
|
|
1697
|
-
*/
|
|
1698
|
-
get messageExpirationFromMillis() {
|
|
1699
|
-
const ret = wasm.__wbg_get_creategroupoptions_messageExpirationFromMillis(this.__wbg_ptr);
|
|
1700
|
-
return ret[0] === 0 ? undefined : ret[1];
|
|
1701
|
-
}
|
|
1702
|
-
/**
|
|
1703
|
-
* @param {bigint | null} [arg0]
|
|
1704
|
-
*/
|
|
1705
|
-
set messageExpirationFromMillis(arg0) {
|
|
1706
|
-
wasm.__wbg_set_creategroupoptions_messageExpirationFromMillis(this.__wbg_ptr, !isLikeNone(arg0), isLikeNone(arg0) ? BigInt(0) : arg0);
|
|
1707
|
-
}
|
|
1708
|
-
/**
|
|
1709
|
-
* @returns {bigint | undefined}
|
|
1606
|
+
* @returns {MessageDisappearingSettings | undefined}
|
|
1710
1607
|
*/
|
|
1711
|
-
get
|
|
1712
|
-
const ret = wasm.
|
|
1713
|
-
return ret
|
|
1608
|
+
get messageDisappearingSettings() {
|
|
1609
|
+
const ret = wasm.__wbg_get_creategroupoptions_messageDisappearingSettings(this.__wbg_ptr);
|
|
1610
|
+
return ret === 0 ? undefined : MessageDisappearingSettings.__wrap(ret);
|
|
1714
1611
|
}
|
|
1715
1612
|
/**
|
|
1716
|
-
* @param {
|
|
1613
|
+
* @param {MessageDisappearingSettings | null} [arg0]
|
|
1717
1614
|
*/
|
|
1718
|
-
set
|
|
1719
|
-
|
|
1615
|
+
set messageDisappearingSettings(arg0) {
|
|
1616
|
+
let ptr0 = 0;
|
|
1617
|
+
if (!isLikeNone(arg0)) {
|
|
1618
|
+
_assertClass(arg0, MessageDisappearingSettings);
|
|
1619
|
+
ptr0 = arg0.__destroy_into_raw();
|
|
1620
|
+
}
|
|
1621
|
+
wasm.__wbg_set_creategroupoptions_messageDisappearingSettings(this.__wbg_ptr, ptr0);
|
|
1720
1622
|
}
|
|
1721
1623
|
/**
|
|
1722
1624
|
* @param {GroupPermissionsOptions | null} [permissions]
|
|
1723
1625
|
* @param {string | null} [group_name]
|
|
1724
1626
|
* @param {string | null} [group_image_url_square]
|
|
1725
1627
|
* @param {string | null} [group_description]
|
|
1726
|
-
* @param {string | null} [group_pinned_frame_url]
|
|
1727
1628
|
* @param {PermissionPolicySet | null} [custom_permission_policy_set]
|
|
1728
|
-
* @param {
|
|
1729
|
-
* @param {bigint | null} [message_expiration_ms]
|
|
1629
|
+
* @param {MessageDisappearingSettings | null} [message_disappearing_settings]
|
|
1730
1630
|
*/
|
|
1731
|
-
constructor(permissions, group_name, group_image_url_square, group_description,
|
|
1631
|
+
constructor(permissions, group_name, group_image_url_square, group_description, custom_permission_policy_set, message_disappearing_settings) {
|
|
1732
1632
|
var ptr0 = isLikeNone(group_name) ? 0 : passStringToWasm0(group_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1733
1633
|
var len0 = WASM_VECTOR_LEN;
|
|
1734
1634
|
var ptr1 = isLikeNone(group_image_url_square) ? 0 : passStringToWasm0(group_image_url_square, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1735
1635
|
var len1 = WASM_VECTOR_LEN;
|
|
1736
1636
|
var ptr2 = isLikeNone(group_description) ? 0 : passStringToWasm0(group_description, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1737
1637
|
var len2 = WASM_VECTOR_LEN;
|
|
1738
|
-
|
|
1739
|
-
var len3 = WASM_VECTOR_LEN;
|
|
1740
|
-
let ptr4 = 0;
|
|
1638
|
+
let ptr3 = 0;
|
|
1741
1639
|
if (!isLikeNone(custom_permission_policy_set)) {
|
|
1742
1640
|
_assertClass(custom_permission_policy_set, PermissionPolicySet);
|
|
1743
|
-
|
|
1641
|
+
ptr3 = custom_permission_policy_set.__destroy_into_raw();
|
|
1642
|
+
}
|
|
1643
|
+
let ptr4 = 0;
|
|
1644
|
+
if (!isLikeNone(message_disappearing_settings)) {
|
|
1645
|
+
_assertClass(message_disappearing_settings, MessageDisappearingSettings);
|
|
1646
|
+
ptr4 = message_disappearing_settings.__destroy_into_raw();
|
|
1744
1647
|
}
|
|
1745
|
-
const ret = wasm.creategroupoptions_new(isLikeNone(permissions) ? 3 : permissions, ptr0, len0, ptr1, len1, ptr2, len2, ptr3,
|
|
1648
|
+
const ret = wasm.creategroupoptions_new(isLikeNone(permissions) ? 3 : permissions, ptr0, len0, ptr1, len1, ptr2, len2, ptr3, ptr4);
|
|
1746
1649
|
this.__wbg_ptr = ret >>> 0;
|
|
1747
1650
|
CreateGroupOptionsFinalization.register(this, this.__wbg_ptr, this);
|
|
1748
1651
|
return this;
|
|
@@ -1806,15 +1709,12 @@ export class EncodedContent {
|
|
|
1806
1709
|
wasm.__wbg_set_encodedcontent_parameters(this.__wbg_ptr, arg0);
|
|
1807
1710
|
}
|
|
1808
1711
|
/**
|
|
1809
|
-
* @returns {string
|
|
1712
|
+
* @returns {string}
|
|
1810
1713
|
*/
|
|
1811
1714
|
get fallback() {
|
|
1812
1715
|
const ret = wasm.__wbg_get_encodedcontent_fallback(this.__wbg_ptr);
|
|
1813
|
-
|
|
1814
|
-
if (ret[0] !== 0) {
|
|
1815
|
-
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
1816
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
1817
|
-
}
|
|
1716
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
1717
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
1818
1718
|
return v1;
|
|
1819
1719
|
}
|
|
1820
1720
|
/**
|
|
@@ -1894,16 +1794,10 @@ export class GroupMember {
|
|
|
1894
1794
|
* @returns {string}
|
|
1895
1795
|
*/
|
|
1896
1796
|
get inboxId() {
|
|
1897
|
-
|
|
1898
|
-
|
|
1899
|
-
|
|
1900
|
-
|
|
1901
|
-
deferred1_0 = ret[0];
|
|
1902
|
-
deferred1_1 = ret[1];
|
|
1903
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
1904
|
-
} finally {
|
|
1905
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
1906
|
-
}
|
|
1797
|
+
const ret = wasm.__wbg_get_groupmember_inboxId(this.__wbg_ptr);
|
|
1798
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
1799
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
1800
|
+
return v1;
|
|
1907
1801
|
}
|
|
1908
1802
|
/**
|
|
1909
1803
|
* @param {string} arg0
|
|
@@ -2023,31 +1917,19 @@ export class GroupMetadata {
|
|
|
2023
1917
|
* @returns {string}
|
|
2024
1918
|
*/
|
|
2025
1919
|
creatorInboxId() {
|
|
2026
|
-
|
|
2027
|
-
|
|
2028
|
-
|
|
2029
|
-
|
|
2030
|
-
deferred1_0 = ret[0];
|
|
2031
|
-
deferred1_1 = ret[1];
|
|
2032
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
2033
|
-
} finally {
|
|
2034
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
2035
|
-
}
|
|
1920
|
+
const ret = wasm.groupmetadata_creatorInboxId(this.__wbg_ptr);
|
|
1921
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
1922
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
1923
|
+
return v1;
|
|
2036
1924
|
}
|
|
2037
1925
|
/**
|
|
2038
1926
|
* @returns {string}
|
|
2039
1927
|
*/
|
|
2040
1928
|
conversationType() {
|
|
2041
|
-
|
|
2042
|
-
|
|
2043
|
-
|
|
2044
|
-
|
|
2045
|
-
deferred1_0 = ret[0];
|
|
2046
|
-
deferred1_1 = ret[1];
|
|
2047
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
2048
|
-
} finally {
|
|
2049
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
2050
|
-
}
|
|
1929
|
+
const ret = wasm.groupmetadata_conversationType(this.__wbg_ptr);
|
|
1930
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
1931
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
1932
|
+
return v1;
|
|
2051
1933
|
}
|
|
2052
1934
|
}
|
|
2053
1935
|
|
|
@@ -2176,16 +2058,10 @@ export class InboxState {
|
|
|
2176
2058
|
* @returns {string}
|
|
2177
2059
|
*/
|
|
2178
2060
|
get inboxId() {
|
|
2179
|
-
|
|
2180
|
-
|
|
2181
|
-
|
|
2182
|
-
|
|
2183
|
-
deferred1_0 = ret[0];
|
|
2184
|
-
deferred1_1 = ret[1];
|
|
2185
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
2186
|
-
} finally {
|
|
2187
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
2188
|
-
}
|
|
2061
|
+
const ret = wasm.__wbg_get_inboxstate_inboxId(this.__wbg_ptr);
|
|
2062
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
2063
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
2064
|
+
return v1;
|
|
2189
2065
|
}
|
|
2190
2066
|
/**
|
|
2191
2067
|
* @param {string} arg0
|
|
@@ -2193,22 +2069,16 @@ export class InboxState {
|
|
|
2193
2069
|
set inboxId(arg0) {
|
|
2194
2070
|
const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
2195
2071
|
const len0 = WASM_VECTOR_LEN;
|
|
2196
|
-
wasm.
|
|
2072
|
+
wasm.__wbg_set_contenttypeid_authorityId(this.__wbg_ptr, ptr0, len0);
|
|
2197
2073
|
}
|
|
2198
2074
|
/**
|
|
2199
2075
|
* @returns {string}
|
|
2200
2076
|
*/
|
|
2201
2077
|
get recoveryAddress() {
|
|
2202
|
-
|
|
2203
|
-
|
|
2204
|
-
|
|
2205
|
-
|
|
2206
|
-
deferred1_0 = ret[0];
|
|
2207
|
-
deferred1_1 = ret[1];
|
|
2208
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
2209
|
-
} finally {
|
|
2210
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
2211
|
-
}
|
|
2078
|
+
const ret = wasm.__wbg_get_inboxstate_recoveryAddress(this.__wbg_ptr);
|
|
2079
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
2080
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
2081
|
+
return v1;
|
|
2212
2082
|
}
|
|
2213
2083
|
/**
|
|
2214
2084
|
* @param {string} arg0
|
|
@@ -2216,7 +2086,7 @@ export class InboxState {
|
|
|
2216
2086
|
set recoveryAddress(arg0) {
|
|
2217
2087
|
const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
2218
2088
|
const len0 = WASM_VECTOR_LEN;
|
|
2219
|
-
wasm.
|
|
2089
|
+
wasm.__wbg_set_contenttypeid_typeId(this.__wbg_ptr, ptr0, len0);
|
|
2220
2090
|
}
|
|
2221
2091
|
/**
|
|
2222
2092
|
* @returns {Installation[]}
|
|
@@ -2323,16 +2193,10 @@ export class Installation {
|
|
|
2323
2193
|
* @returns {string}
|
|
2324
2194
|
*/
|
|
2325
2195
|
get id() {
|
|
2326
|
-
|
|
2327
|
-
|
|
2328
|
-
|
|
2329
|
-
|
|
2330
|
-
deferred1_0 = ret[0];
|
|
2331
|
-
deferred1_1 = ret[1];
|
|
2332
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
2333
|
-
} finally {
|
|
2334
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
2335
|
-
}
|
|
2196
|
+
const ret = wasm.__wbg_get_installation_id(this.__wbg_ptr);
|
|
2197
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
2198
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
2199
|
+
return v1;
|
|
2336
2200
|
}
|
|
2337
2201
|
/**
|
|
2338
2202
|
* @param {string} arg0
|
|
@@ -2557,7 +2421,7 @@ export class ListConversationsOptions {
|
|
|
2557
2421
|
* @param {bigint | null} [arg0]
|
|
2558
2422
|
*/
|
|
2559
2423
|
set createdAfterNs(arg0) {
|
|
2560
|
-
wasm.
|
|
2424
|
+
wasm.__wbg_set_listconversationsoptions_createdAfterNs(this.__wbg_ptr, !isLikeNone(arg0), isLikeNone(arg0) ? BigInt(0) : arg0);
|
|
2561
2425
|
}
|
|
2562
2426
|
/**
|
|
2563
2427
|
* @returns {bigint | undefined}
|
|
@@ -2570,7 +2434,7 @@ export class ListConversationsOptions {
|
|
|
2570
2434
|
* @param {bigint | null} [arg0]
|
|
2571
2435
|
*/
|
|
2572
2436
|
set createdBeforeNs(arg0) {
|
|
2573
|
-
wasm.
|
|
2437
|
+
wasm.__wbg_set_listconversationsoptions_createdBeforeNs(this.__wbg_ptr, !isLikeNone(arg0), isLikeNone(arg0) ? BigInt(0) : arg0);
|
|
2574
2438
|
}
|
|
2575
2439
|
/**
|
|
2576
2440
|
* @returns {bigint | undefined}
|
|
@@ -2630,7 +2494,7 @@ export class ListMessagesOptions {
|
|
|
2630
2494
|
* @param {bigint | null} [arg0]
|
|
2631
2495
|
*/
|
|
2632
2496
|
set sentBeforeNs(arg0) {
|
|
2633
|
-
wasm.
|
|
2497
|
+
wasm.__wbg_set_installation_clientTimestampNs(this.__wbg_ptr, !isLikeNone(arg0), isLikeNone(arg0) ? BigInt(0) : arg0);
|
|
2634
2498
|
}
|
|
2635
2499
|
/**
|
|
2636
2500
|
* @returns {bigint | undefined}
|
|
@@ -2643,7 +2507,7 @@ export class ListMessagesOptions {
|
|
|
2643
2507
|
* @param {bigint | null} [arg0]
|
|
2644
2508
|
*/
|
|
2645
2509
|
set sentAfterNs(arg0) {
|
|
2646
|
-
wasm.
|
|
2510
|
+
wasm.__wbg_set_listmessagesoptions_sentAfterNs(this.__wbg_ptr, !isLikeNone(arg0), isLikeNone(arg0) ? BigInt(0) : arg0);
|
|
2647
2511
|
}
|
|
2648
2512
|
/**
|
|
2649
2513
|
* @returns {bigint | undefined}
|
|
@@ -2656,7 +2520,7 @@ export class ListMessagesOptions {
|
|
|
2656
2520
|
* @param {bigint | null} [arg0]
|
|
2657
2521
|
*/
|
|
2658
2522
|
set limit(arg0) {
|
|
2659
|
-
wasm.
|
|
2523
|
+
wasm.__wbg_set_listmessagesoptions_limit(this.__wbg_ptr, !isLikeNone(arg0), isLikeNone(arg0) ? BigInt(0) : arg0);
|
|
2660
2524
|
}
|
|
2661
2525
|
/**
|
|
2662
2526
|
* @returns {DeliveryStatus | undefined}
|
|
@@ -2805,16 +2669,10 @@ export class Message {
|
|
|
2805
2669
|
* @returns {string}
|
|
2806
2670
|
*/
|
|
2807
2671
|
get id() {
|
|
2808
|
-
|
|
2809
|
-
|
|
2810
|
-
|
|
2811
|
-
|
|
2812
|
-
deferred1_0 = ret[0];
|
|
2813
|
-
deferred1_1 = ret[1];
|
|
2814
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
2815
|
-
} finally {
|
|
2816
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
2817
|
-
}
|
|
2672
|
+
const ret = wasm.__wbg_get_message_id(this.__wbg_ptr);
|
|
2673
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
2674
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
2675
|
+
return v1;
|
|
2818
2676
|
}
|
|
2819
2677
|
/**
|
|
2820
2678
|
* @param {string} arg0
|
|
@@ -2828,29 +2686,23 @@ export class Message {
|
|
|
2828
2686
|
* @returns {bigint}
|
|
2829
2687
|
*/
|
|
2830
2688
|
get sentAtNs() {
|
|
2831
|
-
const ret = wasm.
|
|
2689
|
+
const ret = wasm.__wbg_get_message_sentAtNs(this.__wbg_ptr);
|
|
2832
2690
|
return ret;
|
|
2833
2691
|
}
|
|
2834
2692
|
/**
|
|
2835
2693
|
* @param {bigint} arg0
|
|
2836
2694
|
*/
|
|
2837
2695
|
set sentAtNs(arg0) {
|
|
2838
|
-
wasm.
|
|
2696
|
+
wasm.__wbg_set_message_sentAtNs(this.__wbg_ptr, arg0);
|
|
2839
2697
|
}
|
|
2840
2698
|
/**
|
|
2841
2699
|
* @returns {string}
|
|
2842
2700
|
*/
|
|
2843
2701
|
get convoId() {
|
|
2844
|
-
|
|
2845
|
-
|
|
2846
|
-
|
|
2847
|
-
|
|
2848
|
-
deferred1_0 = ret[0];
|
|
2849
|
-
deferred1_1 = ret[1];
|
|
2850
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
2851
|
-
} finally {
|
|
2852
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
2853
|
-
}
|
|
2702
|
+
const ret = wasm.__wbg_get_message_convoId(this.__wbg_ptr);
|
|
2703
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
2704
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
2705
|
+
return v1;
|
|
2854
2706
|
}
|
|
2855
2707
|
/**
|
|
2856
2708
|
* @param {string} arg0
|
|
@@ -2864,16 +2716,10 @@ export class Message {
|
|
|
2864
2716
|
* @returns {string}
|
|
2865
2717
|
*/
|
|
2866
2718
|
get senderInboxId() {
|
|
2867
|
-
|
|
2868
|
-
|
|
2869
|
-
|
|
2870
|
-
|
|
2871
|
-
deferred1_0 = ret[0];
|
|
2872
|
-
deferred1_1 = ret[1];
|
|
2873
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
2874
|
-
} finally {
|
|
2875
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
2876
|
-
}
|
|
2719
|
+
const ret = wasm.__wbg_get_message_senderInboxId(this.__wbg_ptr);
|
|
2720
|
+
var v1 = getCachedStringFromWasm0(ret[0], ret[1]);
|
|
2721
|
+
if (ret[0] !== 0) { wasm.__wbindgen_free(ret[0], ret[1], 1); }
|
|
2722
|
+
return v1;
|
|
2877
2723
|
}
|
|
2878
2724
|
/**
|
|
2879
2725
|
* @param {string} arg0
|
|
@@ -2949,6 +2795,33 @@ export class Message {
|
|
|
2949
2795
|
}
|
|
2950
2796
|
}
|
|
2951
2797
|
|
|
2798
|
+
const MessageDisappearingSettingsFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
2799
|
+
? { register: () => {}, unregister: () => {} }
|
|
2800
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_messagedisappearingsettings_free(ptr >>> 0, 1));
|
|
2801
|
+
|
|
2802
|
+
export class MessageDisappearingSettings {
|
|
2803
|
+
|
|
2804
|
+
static __wrap(ptr) {
|
|
2805
|
+
ptr = ptr >>> 0;
|
|
2806
|
+
const obj = Object.create(MessageDisappearingSettings.prototype);
|
|
2807
|
+
obj.__wbg_ptr = ptr;
|
|
2808
|
+
MessageDisappearingSettingsFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
2809
|
+
return obj;
|
|
2810
|
+
}
|
|
2811
|
+
|
|
2812
|
+
__destroy_into_raw() {
|
|
2813
|
+
const ptr = this.__wbg_ptr;
|
|
2814
|
+
this.__wbg_ptr = 0;
|
|
2815
|
+
MessageDisappearingSettingsFinalization.unregister(this);
|
|
2816
|
+
return ptr;
|
|
2817
|
+
}
|
|
2818
|
+
|
|
2819
|
+
free() {
|
|
2820
|
+
const ptr = this.__destroy_into_raw();
|
|
2821
|
+
wasm.__wbg_messagedisappearingsettings_free(ptr, 0);
|
|
2822
|
+
}
|
|
2823
|
+
}
|
|
2824
|
+
|
|
2952
2825
|
const PermissionPolicySetFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
2953
2826
|
? { register: () => {}, unregister: () => {} }
|
|
2954
2827
|
: new FinalizationRegistry(ptr => wasm.__wbg_permissionpolicyset_free(ptr >>> 0, 1));
|
|
@@ -3068,28 +2941,15 @@ export class PermissionPolicySet {
|
|
|
3068
2941
|
/**
|
|
3069
2942
|
* @returns {PermissionPolicy}
|
|
3070
2943
|
*/
|
|
3071
|
-
get
|
|
3072
|
-
const ret = wasm.
|
|
3073
|
-
return ret;
|
|
3074
|
-
}
|
|
3075
|
-
/**
|
|
3076
|
-
* @param {PermissionPolicy} arg0
|
|
3077
|
-
*/
|
|
3078
|
-
set updateGroupPinnedFrameUrlPolicy(arg0) {
|
|
3079
|
-
wasm.__wbg_set_permissionpolicyset_updateGroupPinnedFrameUrlPolicy(this.__wbg_ptr, arg0);
|
|
3080
|
-
}
|
|
3081
|
-
/**
|
|
3082
|
-
* @returns {PermissionPolicy}
|
|
3083
|
-
*/
|
|
3084
|
-
get updateMessageExpirationPolicy() {
|
|
3085
|
-
const ret = wasm.__wbg_get_permissionpolicyset_updateMessageExpirationPolicy(this.__wbg_ptr);
|
|
2944
|
+
get updateMessageDisappearingPolicy() {
|
|
2945
|
+
const ret = wasm.__wbg_get_permissionpolicyset_updateMessageDisappearingPolicy(this.__wbg_ptr);
|
|
3086
2946
|
return ret;
|
|
3087
2947
|
}
|
|
3088
2948
|
/**
|
|
3089
2949
|
* @param {PermissionPolicy} arg0
|
|
3090
2950
|
*/
|
|
3091
|
-
set
|
|
3092
|
-
wasm.
|
|
2951
|
+
set updateMessageDisappearingPolicy(arg0) {
|
|
2952
|
+
wasm.__wbg_set_permissionpolicyset_updateMessageDisappearingPolicy(this.__wbg_ptr, arg0);
|
|
3093
2953
|
}
|
|
3094
2954
|
/**
|
|
3095
2955
|
* @param {PermissionPolicy} add_member_policy
|
|
@@ -3099,17 +2959,75 @@ export class PermissionPolicySet {
|
|
|
3099
2959
|
* @param {PermissionPolicy} update_group_name_policy
|
|
3100
2960
|
* @param {PermissionPolicy} update_group_description_policy
|
|
3101
2961
|
* @param {PermissionPolicy} update_group_image_url_square_policy
|
|
3102
|
-
* @param {PermissionPolicy}
|
|
3103
|
-
* @param {PermissionPolicy} update_message_expiration_ms_policy
|
|
2962
|
+
* @param {PermissionPolicy} update_message_disappearing_policy
|
|
3104
2963
|
*/
|
|
3105
|
-
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,
|
|
3106
|
-
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,
|
|
2964
|
+
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) {
|
|
2965
|
+
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);
|
|
3107
2966
|
this.__wbg_ptr = ret >>> 0;
|
|
3108
2967
|
PermissionPolicySetFinalization.register(this, this.__wbg_ptr, this);
|
|
3109
2968
|
return this;
|
|
3110
2969
|
}
|
|
3111
2970
|
}
|
|
3112
2971
|
|
|
2972
|
+
const StreamCloserFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
2973
|
+
? { register: () => {}, unregister: () => {} }
|
|
2974
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_streamcloser_free(ptr >>> 0, 1));
|
|
2975
|
+
|
|
2976
|
+
export class StreamCloser {
|
|
2977
|
+
|
|
2978
|
+
static __wrap(ptr) {
|
|
2979
|
+
ptr = ptr >>> 0;
|
|
2980
|
+
const obj = Object.create(StreamCloser.prototype);
|
|
2981
|
+
obj.__wbg_ptr = ptr;
|
|
2982
|
+
StreamCloserFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
2983
|
+
return obj;
|
|
2984
|
+
}
|
|
2985
|
+
|
|
2986
|
+
__destroy_into_raw() {
|
|
2987
|
+
const ptr = this.__wbg_ptr;
|
|
2988
|
+
this.__wbg_ptr = 0;
|
|
2989
|
+
StreamCloserFinalization.unregister(this);
|
|
2990
|
+
return ptr;
|
|
2991
|
+
}
|
|
2992
|
+
|
|
2993
|
+
free() {
|
|
2994
|
+
const ptr = this.__destroy_into_raw();
|
|
2995
|
+
wasm.__wbg_streamcloser_free(ptr, 0);
|
|
2996
|
+
}
|
|
2997
|
+
/**
|
|
2998
|
+
* Signal the stream to end
|
|
2999
|
+
* Does not wait for the stream to end.
|
|
3000
|
+
*/
|
|
3001
|
+
end() {
|
|
3002
|
+
wasm.streamcloser_end(this.__wbg_ptr);
|
|
3003
|
+
}
|
|
3004
|
+
/**
|
|
3005
|
+
* End the stream and `await` for it to shutdown
|
|
3006
|
+
* Returns the `Result` of the task.
|
|
3007
|
+
* End the stream and asynchronously wait for it to shutdown
|
|
3008
|
+
* @returns {Promise<void>}
|
|
3009
|
+
*/
|
|
3010
|
+
endAndWait() {
|
|
3011
|
+
const ret = wasm.streamcloser_endAndWait(this.__wbg_ptr);
|
|
3012
|
+
return ret;
|
|
3013
|
+
}
|
|
3014
|
+
/**
|
|
3015
|
+
* @returns {Promise<void>}
|
|
3016
|
+
*/
|
|
3017
|
+
waitForReady() {
|
|
3018
|
+
const ret = wasm.streamcloser_waitForReady(this.__wbg_ptr);
|
|
3019
|
+
return ret;
|
|
3020
|
+
}
|
|
3021
|
+
/**
|
|
3022
|
+
* Checks if this stream is closed
|
|
3023
|
+
* @returns {boolean}
|
|
3024
|
+
*/
|
|
3025
|
+
isClosed() {
|
|
3026
|
+
const ret = wasm.streamcloser_isClosed(this.__wbg_ptr);
|
|
3027
|
+
return ret !== 0;
|
|
3028
|
+
}
|
|
3029
|
+
}
|
|
3030
|
+
|
|
3113
3031
|
const VersionFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
3114
3032
|
? { register: () => {}, unregister: () => {} }
|
|
3115
3033
|
: new FinalizationRegistry(ptr => wasm.__wbg_version_free(ptr >>> 0, 1));
|
|
@@ -3246,16 +3164,10 @@ function __wbg_get_imports() {
|
|
|
3246
3164
|
arg0.abort();
|
|
3247
3165
|
};
|
|
3248
3166
|
imports.wbg.__wbg_allocCString_69f9010fb2b096f0 = function(arg0, arg1, arg2) {
|
|
3249
|
-
|
|
3250
|
-
|
|
3251
|
-
|
|
3252
|
-
|
|
3253
|
-
deferred0_1 = arg2;
|
|
3254
|
-
const ret = arg0.allocCString(getStringFromWasm0(arg1, arg2));
|
|
3255
|
-
return ret;
|
|
3256
|
-
} finally {
|
|
3257
|
-
wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
|
|
3258
|
-
}
|
|
3167
|
+
var v0 = getCachedStringFromWasm0(arg1, arg2);
|
|
3168
|
+
if (arg1 !== 0) { wasm.__wbindgen_free(arg1, arg2, 1); }
|
|
3169
|
+
const ret = arg0.allocCString(v0);
|
|
3170
|
+
return ret;
|
|
3259
3171
|
};
|
|
3260
3172
|
imports.wbg.__wbg_allocPtr_c83ee345784d444f = function(arg0, arg1, arg2) {
|
|
3261
3173
|
const ret = arg0.allocPtr(arg1 >>> 0, arg2 !== 0);
|
|
@@ -3274,7 +3186,9 @@ function __wbg_get_imports() {
|
|
|
3274
3186
|
return ret;
|
|
3275
3187
|
};
|
|
3276
3188
|
imports.wbg.__wbg_append_8c7dd8d641a5f01b = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
|
|
3277
|
-
|
|
3189
|
+
var v0 = getCachedStringFromWasm0(arg1, arg2);
|
|
3190
|
+
var v1 = getCachedStringFromWasm0(arg3, arg4);
|
|
3191
|
+
arg0.append(v0, v1);
|
|
3278
3192
|
}, arguments) };
|
|
3279
3193
|
imports.wbg.__wbg_arrayBuffer_d1b44c4390db422f = function() { return handleError(function (arg0) {
|
|
3280
3194
|
const ret = arg0.arrayBuffer();
|
|
@@ -3304,6 +3218,10 @@ function __wbg_get_imports() {
|
|
|
3304
3218
|
const ret = arg0.bind_text(arg1, arg2, arg3 >>> 0, arg4, arg5);
|
|
3305
3219
|
return ret;
|
|
3306
3220
|
};
|
|
3221
|
+
imports.wbg.__wbg_body_0b8fd1fe671660df = function(arg0) {
|
|
3222
|
+
const ret = arg0.body;
|
|
3223
|
+
return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
|
|
3224
|
+
};
|
|
3307
3225
|
imports.wbg.__wbg_buffer_09165b52af8c5237 = function(arg0) {
|
|
3308
3226
|
const ret = arg0.buffer;
|
|
3309
3227
|
return ret;
|
|
@@ -3332,10 +3250,18 @@ function __wbg_get_imports() {
|
|
|
3332
3250
|
const ret = arg0.call(arg1, arg2);
|
|
3333
3251
|
return ret;
|
|
3334
3252
|
}, arguments) };
|
|
3253
|
+
imports.wbg.__wbg_cancel_8a308660caa6cadf = function(arg0) {
|
|
3254
|
+
const ret = arg0.cancel();
|
|
3255
|
+
return ret;
|
|
3256
|
+
};
|
|
3335
3257
|
imports.wbg.__wbg_capi_b2cd9cd3325d1164 = function(arg0) {
|
|
3336
3258
|
const ret = arg0.capi;
|
|
3337
3259
|
return ret;
|
|
3338
3260
|
};
|
|
3261
|
+
imports.wbg.__wbg_catch_a6e601879b2610e9 = function(arg0, arg1) {
|
|
3262
|
+
const ret = arg0.catch(arg1);
|
|
3263
|
+
return ret;
|
|
3264
|
+
};
|
|
3339
3265
|
imports.wbg.__wbg_changes_8f2cadd92748538c = function(arg0, arg1) {
|
|
3340
3266
|
const ret = arg0.changes(arg1);
|
|
3341
3267
|
return ret;
|
|
@@ -3420,15 +3346,9 @@ function __wbg_get_imports() {
|
|
|
3420
3346
|
console.error(arg0);
|
|
3421
3347
|
};
|
|
3422
3348
|
imports.wbg.__wbg_error_7534b8e9a36f1ab4 = function(arg0, arg1) {
|
|
3423
|
-
|
|
3424
|
-
|
|
3425
|
-
|
|
3426
|
-
deferred0_0 = arg0;
|
|
3427
|
-
deferred0_1 = arg1;
|
|
3428
|
-
console.error(getStringFromWasm0(arg0, arg1));
|
|
3429
|
-
} finally {
|
|
3430
|
-
wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
|
|
3431
|
-
}
|
|
3349
|
+
var v0 = getCachedStringFromWasm0(arg0, arg1);
|
|
3350
|
+
if (arg0 !== 0) { wasm.__wbindgen_free(arg0, arg1, 1); }
|
|
3351
|
+
console.error(v0);
|
|
3432
3352
|
};
|
|
3433
3353
|
imports.wbg.__wbg_error_80de38b3f7cc3c3c = function(arg0, arg1, arg2, arg3) {
|
|
3434
3354
|
console.error(arg0, arg1, arg2, arg3);
|
|
@@ -3441,34 +3361,29 @@ function __wbg_get_imports() {
|
|
|
3441
3361
|
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
3442
3362
|
};
|
|
3443
3363
|
imports.wbg.__wbg_exec_fd553de4a4a4f848 = function() { return handleError(function (arg0, arg1, arg2, arg3) {
|
|
3444
|
-
|
|
3364
|
+
var v0 = getCachedStringFromWasm0(arg2, arg3);
|
|
3365
|
+
arg0.exec(arg1, v0);
|
|
3445
3366
|
}, arguments) };
|
|
3446
3367
|
imports.wbg.__wbg_extendederrcode_0835da64030ca814 = function(arg0, arg1) {
|
|
3447
3368
|
const ret = arg0.extended_errcode(arg1);
|
|
3448
3369
|
return ret;
|
|
3449
3370
|
};
|
|
3450
|
-
imports.wbg.
|
|
3451
|
-
const ret =
|
|
3371
|
+
imports.wbg.__wbg_fetch_4465c2b10f21a927 = function(arg0) {
|
|
3372
|
+
const ret = fetch(arg0);
|
|
3452
3373
|
return ret;
|
|
3453
3374
|
};
|
|
3454
|
-
imports.wbg.
|
|
3455
|
-
const ret = fetch(
|
|
3375
|
+
imports.wbg.__wbg_fetch_509096533071c657 = function(arg0, arg1) {
|
|
3376
|
+
const ret = arg0.fetch(arg1);
|
|
3456
3377
|
return ret;
|
|
3457
3378
|
};
|
|
3458
3379
|
imports.wbg.__wbg_filename_0235553cd4665109 = function(arg0, arg1, arg2, arg3, arg4) {
|
|
3459
|
-
|
|
3460
|
-
|
|
3461
|
-
|
|
3462
|
-
|
|
3463
|
-
|
|
3464
|
-
|
|
3465
|
-
|
|
3466
|
-
const len2 = WASM_VECTOR_LEN;
|
|
3467
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 1, len2, true);
|
|
3468
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr2, true);
|
|
3469
|
-
} finally {
|
|
3470
|
-
wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
|
|
3471
|
-
}
|
|
3380
|
+
var v0 = getCachedStringFromWasm0(arg3, arg4);
|
|
3381
|
+
if (arg3 !== 0) { wasm.__wbindgen_free(arg3, arg4, 1); }
|
|
3382
|
+
const ret = arg1.filename(arg2, v0);
|
|
3383
|
+
const ptr2 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
3384
|
+
const len2 = WASM_VECTOR_LEN;
|
|
3385
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 1, len2, true);
|
|
3386
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr2, true);
|
|
3472
3387
|
};
|
|
3473
3388
|
imports.wbg.__wbg_finalize_429654d82c434d47 = function() { return handleError(function (arg0, arg1) {
|
|
3474
3389
|
arg0.finalize(arg1);
|
|
@@ -3476,6 +3391,10 @@ function __wbg_get_imports() {
|
|
|
3476
3391
|
imports.wbg.__wbg_getRandomValues_bcb4912f16000dc4 = function() { return handleError(function (arg0, arg1) {
|
|
3477
3392
|
arg0.getRandomValues(arg1);
|
|
3478
3393
|
}, arguments) };
|
|
3394
|
+
imports.wbg.__wbg_getReader_48e00749fe3f6089 = function() { return handleError(function (arg0) {
|
|
3395
|
+
const ret = arg0.getReader();
|
|
3396
|
+
return ret;
|
|
3397
|
+
}, arguments) };
|
|
3479
3398
|
imports.wbg.__wbg_get_67b2ba62fc30de12 = function() { return handleError(function (arg0, arg1) {
|
|
3480
3399
|
const ret = Reflect.get(arg0, arg1);
|
|
3481
3400
|
return ret;
|
|
@@ -3484,6 +3403,14 @@ function __wbg_get_imports() {
|
|
|
3484
3403
|
const ret = arg0[arg1 >>> 0];
|
|
3485
3404
|
return ret;
|
|
3486
3405
|
};
|
|
3406
|
+
imports.wbg.__wbg_getdone_d47073731acd3e74 = function(arg0) {
|
|
3407
|
+
const ret = arg0.done;
|
|
3408
|
+
return isLikeNone(ret) ? 0xFFFFFF : ret ? 1 : 0;
|
|
3409
|
+
};
|
|
3410
|
+
imports.wbg.__wbg_getvalue_009dcd63692bee1f = function(arg0) {
|
|
3411
|
+
const ret = arg0.value;
|
|
3412
|
+
return ret;
|
|
3413
|
+
};
|
|
3487
3414
|
imports.wbg.__wbg_getwithrefkey_1dc361bd10053bfe = function(arg0, arg1) {
|
|
3488
3415
|
const ret = arg0[arg1];
|
|
3489
3416
|
return ret;
|
|
@@ -3587,16 +3514,22 @@ function __wbg_get_imports() {
|
|
|
3587
3514
|
return ret;
|
|
3588
3515
|
};
|
|
3589
3516
|
imports.wbg.__wbg_mark_05056c522bddc362 = function() { return handleError(function (arg0, arg1, arg2) {
|
|
3590
|
-
|
|
3517
|
+
var v0 = getCachedStringFromWasm0(arg1, arg2);
|
|
3518
|
+
arg0.mark(v0);
|
|
3591
3519
|
}, arguments) };
|
|
3592
3520
|
imports.wbg.__wbg_mark_24a1a597f4f00679 = function() { return handleError(function (arg0, arg1, arg2, arg3) {
|
|
3593
|
-
|
|
3521
|
+
var v0 = getCachedStringFromWasm0(arg1, arg2);
|
|
3522
|
+
arg0.mark(v0, arg3);
|
|
3594
3523
|
}, arguments) };
|
|
3595
3524
|
imports.wbg.__wbg_measure_0b7379f5cfacac6d = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4, arg5, arg6) {
|
|
3596
|
-
|
|
3525
|
+
var v0 = getCachedStringFromWasm0(arg1, arg2);
|
|
3526
|
+
var v1 = getCachedStringFromWasm0(arg3, arg4);
|
|
3527
|
+
var v2 = getCachedStringFromWasm0(arg5, arg6);
|
|
3528
|
+
arg0.measure(v0, v1, v2);
|
|
3597
3529
|
}, arguments) };
|
|
3598
3530
|
imports.wbg.__wbg_measure_7728846525e2cced = function() { return handleError(function (arg0, arg1, arg2, arg3) {
|
|
3599
|
-
|
|
3531
|
+
var v0 = getCachedStringFromWasm0(arg1, arg2);
|
|
3532
|
+
arg0.measure(v0, arg3);
|
|
3600
3533
|
}, arguments) };
|
|
3601
3534
|
imports.wbg.__wbg_message_new = function(arg0) {
|
|
3602
3535
|
const ret = Message.__wrap(arg0);
|
|
@@ -3617,7 +3550,7 @@ function __wbg_get_imports() {
|
|
|
3617
3550
|
const a = state0.a;
|
|
3618
3551
|
state0.a = 0;
|
|
3619
3552
|
try {
|
|
3620
|
-
return
|
|
3553
|
+
return __wbg_adapter_612(a, state0.b, arg0, arg1);
|
|
3621
3554
|
} finally {
|
|
3622
3555
|
state0.a = a;
|
|
3623
3556
|
}
|
|
@@ -3657,7 +3590,8 @@ function __wbg_get_imports() {
|
|
|
3657
3590
|
return ret;
|
|
3658
3591
|
};
|
|
3659
3592
|
imports.wbg.__wbg_new_c68d7209be747379 = function(arg0, arg1) {
|
|
3660
|
-
|
|
3593
|
+
var v0 = getCachedStringFromWasm0(arg0, arg1);
|
|
3594
|
+
const ret = new Error(v0);
|
|
3661
3595
|
return ret;
|
|
3662
3596
|
};
|
|
3663
3597
|
imports.wbg.__wbg_new_e25e5aab09ff45db = function() { return handleError(function () {
|
|
@@ -3665,7 +3599,8 @@ function __wbg_get_imports() {
|
|
|
3665
3599
|
return ret;
|
|
3666
3600
|
}, arguments) };
|
|
3667
3601
|
imports.wbg.__wbg_newnoargs_105ed471475aaf50 = function(arg0, arg1) {
|
|
3668
|
-
|
|
3602
|
+
var v0 = getCachedStringFromWasm0(arg0, arg1);
|
|
3603
|
+
const ret = new Function(v0);
|
|
3669
3604
|
return ret;
|
|
3670
3605
|
};
|
|
3671
3606
|
imports.wbg.__wbg_newwithbyteoffsetandlength_d97e637ebe145a9a = function(arg0, arg1, arg2) {
|
|
@@ -3677,7 +3612,8 @@ function __wbg_get_imports() {
|
|
|
3677
3612
|
return ret;
|
|
3678
3613
|
};
|
|
3679
3614
|
imports.wbg.__wbg_newwithstrandinit_06c535e0a867c635 = function() { return handleError(function (arg0, arg1, arg2) {
|
|
3680
|
-
|
|
3615
|
+
var v0 = getCachedStringFromWasm0(arg0, arg1);
|
|
3616
|
+
const ret = new Request(v0, arg2);
|
|
3681
3617
|
return ret;
|
|
3682
3618
|
}, arguments) };
|
|
3683
3619
|
imports.wbg.__wbg_next_25feadfc0913fea9 = function(arg0) {
|
|
@@ -3696,8 +3632,18 @@ function __wbg_get_imports() {
|
|
|
3696
3632
|
const ret = Date.now();
|
|
3697
3633
|
return ret;
|
|
3698
3634
|
};
|
|
3635
|
+
imports.wbg.__wbg_onconversation_43aee3fe67697518 = function(arg0, arg1) {
|
|
3636
|
+
arg0.on_conversation(Conversation.__wrap(arg1));
|
|
3637
|
+
};
|
|
3638
|
+
imports.wbg.__wbg_onerror_58742435b241fdbd = function(arg0, arg1) {
|
|
3639
|
+
arg0.on_error(arg1);
|
|
3640
|
+
};
|
|
3641
|
+
imports.wbg.__wbg_onmessage_12923aab4231469e = function(arg0, arg1) {
|
|
3642
|
+
arg0.on_message(Message.__wrap(arg1));
|
|
3643
|
+
};
|
|
3699
3644
|
imports.wbg.__wbg_open_aba34ed1b3b52dc4 = function() { return handleError(function (arg0, arg1, arg2, arg3) {
|
|
3700
|
-
|
|
3645
|
+
var v0 = getCachedStringFromWasm0(arg1, arg2);
|
|
3646
|
+
const ret = arg0.open(v0, arg3 === 0x100000001 ? undefined : arg3);
|
|
3701
3647
|
return ret;
|
|
3702
3648
|
}, arguments) };
|
|
3703
3649
|
imports.wbg.__wbg_peekPtr_6a7d4078b4e26f07 = function(arg0, arg1) {
|
|
@@ -3738,9 +3684,16 @@ function __wbg_get_imports() {
|
|
|
3738
3684
|
imports.wbg.__wbg_randomFillSync_ab2cfe79ebbf2740 = function() { return handleError(function (arg0, arg1) {
|
|
3739
3685
|
arg0.randomFillSync(arg1);
|
|
3740
3686
|
}, arguments) };
|
|
3687
|
+
imports.wbg.__wbg_read_a2434af1186cb56c = function(arg0) {
|
|
3688
|
+
const ret = arg0.read();
|
|
3689
|
+
return ret;
|
|
3690
|
+
};
|
|
3741
3691
|
imports.wbg.__wbg_registerdieselsqlfunctions_f374322dbb736b21 = function() { return handleError(function (arg0, arg1) {
|
|
3742
3692
|
arg0.register_diesel_sql_functions(arg1);
|
|
3743
3693
|
}, arguments) };
|
|
3694
|
+
imports.wbg.__wbg_releaseLock_091899af97991d2e = function(arg0) {
|
|
3695
|
+
arg0.releaseLock();
|
|
3696
|
+
};
|
|
3744
3697
|
imports.wbg.__wbg_require_79b1e9274cde3c87 = function() { return handleError(function () {
|
|
3745
3698
|
const ret = module.require;
|
|
3746
3699
|
return ret;
|
|
@@ -3790,7 +3743,8 @@ function __wbg_get_imports() {
|
|
|
3790
3743
|
arg0.headers = arg1;
|
|
3791
3744
|
};
|
|
3792
3745
|
imports.wbg.__wbg_setmethod_3c5280fe5d890842 = function(arg0, arg1, arg2) {
|
|
3793
|
-
|
|
3746
|
+
var v0 = getCachedStringFromWasm0(arg1, arg2);
|
|
3747
|
+
arg0.method = v0;
|
|
3794
3748
|
};
|
|
3795
3749
|
imports.wbg.__wbg_setmode_5dc300b865044b65 = function(arg0, arg1) {
|
|
3796
3750
|
arg0.mode = __wbindgen_enum_RequestMode[arg1];
|
|
@@ -3953,8 +3907,8 @@ function __wbg_get_imports() {
|
|
|
3953
3907
|
const ret = false;
|
|
3954
3908
|
return ret;
|
|
3955
3909
|
};
|
|
3956
|
-
imports.wbg.
|
|
3957
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
3910
|
+
imports.wbg.__wbindgen_closure_wrapper14410 = function(arg0, arg1, arg2) {
|
|
3911
|
+
const ret = makeMutClosure(arg0, arg1, 2901, __wbg_adapter_52);
|
|
3958
3912
|
return ret;
|
|
3959
3913
|
};
|
|
3960
3914
|
imports.wbg.__wbindgen_debug_string = function(arg0, arg1) {
|
|
@@ -3973,7 +3927,7 @@ function __wbg_get_imports() {
|
|
|
3973
3927
|
return ret;
|
|
3974
3928
|
};
|
|
3975
3929
|
imports.wbg.__wbindgen_init_externref_table = function() {
|
|
3976
|
-
const table = wasm.
|
|
3930
|
+
const table = wasm.__wbindgen_export_2;
|
|
3977
3931
|
const offset = table.grow(4);
|
|
3978
3932
|
table.set(0, undefined);
|
|
3979
3933
|
table.set(offset + 0, undefined);
|