saito-wasm 0.2.23 → 0.2.25
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/Cargo.toml +1 -1
- package/package.json +1 -1
- package/pkg/node/index.d.ts +15 -10
- package/pkg/node/index.js +119 -109
- package/pkg/node/index_bg.wasm +0 -0
- package/pkg/node/index_bg.wasm.d.ts +117 -117
- package/pkg/node/package.json +1 -1
- package/pkg/node/snippets/{saito-wasm-890126c2574ee850 → saito-wasm-5c25242fd1d8ed87}/js/msg_handler.js +4 -0
- package/pkg/web/index.d.ts +132 -127
- package/pkg/web/index.js +113 -104
- package/pkg/web/index_bg.wasm +0 -0
- package/pkg/web/index_bg.wasm.d.ts +117 -117
- package/pkg/web/package.json +1 -1
- package/pkg/web/snippets/{saito-wasm-890126c2574ee850 → saito-wasm-5c25242fd1d8ed87}/js/msg_handler.js +4 -0
package/Cargo.toml
CHANGED
package/package.json
CHANGED
package/pkg/node/index.d.ts
CHANGED
|
@@ -39,6 +39,17 @@ export function get_block(block_hash: string): Promise<WasmBlock>;
|
|
|
39
39
|
*/
|
|
40
40
|
export function process_new_peer(peer_index: bigint): Promise<void>;
|
|
41
41
|
/**
|
|
42
|
+
* @param {bigint} peer_index
|
|
43
|
+
* @param {string} public_key
|
|
44
|
+
* @returns {Promise<void>}
|
|
45
|
+
*/
|
|
46
|
+
export function process_stun_peer(peer_index: bigint, public_key: string): Promise<void>;
|
|
47
|
+
/**
|
|
48
|
+
* @param {bigint} peer_index
|
|
49
|
+
* @returns {Promise<void>}
|
|
50
|
+
*/
|
|
51
|
+
export function remove_stun_peer(peer_index: bigint): Promise<void>;
|
|
52
|
+
/**
|
|
42
53
|
* @returns {Promise<bigint>}
|
|
43
54
|
*/
|
|
44
55
|
export function get_next_peer_index(): Promise<bigint>;
|
|
@@ -263,16 +274,16 @@ export class WasmBlock {
|
|
|
263
274
|
readonly avg_total_fees: bigint;
|
|
264
275
|
/**
|
|
265
276
|
*/
|
|
266
|
-
|
|
277
|
+
readonly burnfee: bigint;
|
|
267
278
|
/**
|
|
268
279
|
*/
|
|
269
|
-
|
|
280
|
+
creator: string;
|
|
270
281
|
/**
|
|
271
282
|
*/
|
|
272
|
-
readonly
|
|
283
|
+
readonly cv: any;
|
|
273
284
|
/**
|
|
274
285
|
*/
|
|
275
|
-
readonly
|
|
286
|
+
readonly difficulty: bigint;
|
|
276
287
|
/**
|
|
277
288
|
*/
|
|
278
289
|
readonly fee_transaction: any;
|
|
@@ -313,9 +324,6 @@ export class WasmBlock {
|
|
|
313
324
|
*/
|
|
314
325
|
readonly it_num: number;
|
|
315
326
|
/**
|
|
316
|
-
*/
|
|
317
|
-
readonly nolan_falling_off_chain: bigint;
|
|
318
|
-
/**
|
|
319
327
|
*/
|
|
320
328
|
previous_block_hash: string;
|
|
321
329
|
/**
|
|
@@ -461,9 +469,6 @@ export class WasmConsensusValues {
|
|
|
461
469
|
*/
|
|
462
470
|
readonly it_num: number;
|
|
463
471
|
/**
|
|
464
|
-
*/
|
|
465
|
-
readonly nolan_falling_off_chain: bigint;
|
|
466
|
-
/**
|
|
467
472
|
*/
|
|
468
473
|
readonly rebroadcast_hash: string;
|
|
469
474
|
/**
|
package/pkg/node/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
let imports = {};
|
|
2
2
|
imports['__wbindgen_placeholder__'] = module.exports;
|
|
3
3
|
let wasm;
|
|
4
|
-
const { MsgHandler } = require(String.raw`./snippets/saito-wasm-
|
|
4
|
+
const { MsgHandler } = require(String.raw`./snippets/saito-wasm-5c25242fd1d8ed87/js/msg_handler.js`);
|
|
5
5
|
const { TextDecoder, TextEncoder } = require(`util`);
|
|
6
6
|
|
|
7
7
|
const heap = new Array(128).fill(undefined);
|
|
@@ -225,9 +225,23 @@ function makeMutClosure(arg0, arg1, dtor, f) {
|
|
|
225
225
|
return real;
|
|
226
226
|
}
|
|
227
227
|
function __wbg_adapter_38(arg0, arg1, arg2) {
|
|
228
|
-
wasm.
|
|
228
|
+
wasm._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__ha18c4469c8531320(arg0, arg1, addHeapObject(arg2));
|
|
229
229
|
}
|
|
230
230
|
|
|
231
|
+
function handleError(f, args) {
|
|
232
|
+
try {
|
|
233
|
+
return f.apply(this, args);
|
|
234
|
+
} catch (e) {
|
|
235
|
+
wasm.__wbindgen_exn_store(addHeapObject(e));
|
|
236
|
+
}
|
|
237
|
+
}
|
|
238
|
+
|
|
239
|
+
function _assertClass(instance, klass) {
|
|
240
|
+
if (!(instance instanceof klass)) {
|
|
241
|
+
throw new Error(`expected instance of ${klass.name}`);
|
|
242
|
+
}
|
|
243
|
+
return instance.ptr;
|
|
244
|
+
}
|
|
231
245
|
/**
|
|
232
246
|
* @param {string} json
|
|
233
247
|
* @param {string} private_key
|
|
@@ -290,6 +304,25 @@ module.exports.process_new_peer = function(peer_index) {
|
|
|
290
304
|
return takeObject(ret);
|
|
291
305
|
};
|
|
292
306
|
|
|
307
|
+
/**
|
|
308
|
+
* @param {bigint} peer_index
|
|
309
|
+
* @param {string} public_key
|
|
310
|
+
* @returns {Promise<void>}
|
|
311
|
+
*/
|
|
312
|
+
module.exports.process_stun_peer = function(peer_index, public_key) {
|
|
313
|
+
const ret = wasm.process_stun_peer(peer_index, addHeapObject(public_key));
|
|
314
|
+
return takeObject(ret);
|
|
315
|
+
};
|
|
316
|
+
|
|
317
|
+
/**
|
|
318
|
+
* @param {bigint} peer_index
|
|
319
|
+
* @returns {Promise<void>}
|
|
320
|
+
*/
|
|
321
|
+
module.exports.remove_stun_peer = function(peer_index) {
|
|
322
|
+
const ret = wasm.remove_stun_peer(peer_index);
|
|
323
|
+
return takeObject(ret);
|
|
324
|
+
};
|
|
325
|
+
|
|
293
326
|
/**
|
|
294
327
|
* @returns {Promise<bigint>}
|
|
295
328
|
*/
|
|
@@ -434,12 +467,6 @@ module.exports.get_balance_snapshot = function(keys) {
|
|
|
434
467
|
return takeObject(ret);
|
|
435
468
|
};
|
|
436
469
|
|
|
437
|
-
function _assertClass(instance, klass) {
|
|
438
|
-
if (!(instance instanceof klass)) {
|
|
439
|
-
throw new Error(`expected instance of ${klass.name}`);
|
|
440
|
-
}
|
|
441
|
-
return instance.ptr;
|
|
442
|
-
}
|
|
443
470
|
/**
|
|
444
471
|
* @param {WasmBalanceSnapshot} snapshot
|
|
445
472
|
* @returns {Promise<void>}
|
|
@@ -599,15 +626,8 @@ module.exports.produce_block_without_gt = function() {
|
|
|
599
626
|
return takeObject(ret);
|
|
600
627
|
};
|
|
601
628
|
|
|
602
|
-
function
|
|
603
|
-
|
|
604
|
-
return f.apply(this, args);
|
|
605
|
-
} catch (e) {
|
|
606
|
-
wasm.__wbindgen_exn_store(addHeapObject(e));
|
|
607
|
-
}
|
|
608
|
-
}
|
|
609
|
-
function __wbg_adapter_379(arg0, arg1, arg2, arg3) {
|
|
610
|
-
wasm.wasm_bindgen__convert__closures__invoke2_mut__h2342d2d7ddbab521(arg0, arg1, addHeapObject(arg2), addHeapObject(arg3));
|
|
629
|
+
function __wbg_adapter_381(arg0, arg1, arg2, arg3) {
|
|
630
|
+
wasm.wasm_bindgen__convert__closures__invoke2_mut__h2c2d2984a3f304e5(arg0, arg1, addHeapObject(arg2), addHeapObject(arg3));
|
|
611
631
|
}
|
|
612
632
|
|
|
613
633
|
const SaitoWasmFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
@@ -771,8 +791,8 @@ class WasmBlock {
|
|
|
771
791
|
/**
|
|
772
792
|
* @returns {bigint}
|
|
773
793
|
*/
|
|
774
|
-
get
|
|
775
|
-
const ret = wasm.
|
|
794
|
+
get burnfee() {
|
|
795
|
+
const ret = wasm.wasmblock_burnfee(this.__wbg_ptr);
|
|
776
796
|
return BigInt.asUintN(64, ret);
|
|
777
797
|
}
|
|
778
798
|
/**
|
|
@@ -813,8 +833,8 @@ class WasmBlock {
|
|
|
813
833
|
/**
|
|
814
834
|
* @returns {bigint}
|
|
815
835
|
*/
|
|
816
|
-
get
|
|
817
|
-
const ret = wasm.
|
|
836
|
+
get difficulty() {
|
|
837
|
+
const ret = wasm.wasmblock_difficulty(this.__wbg_ptr);
|
|
818
838
|
return BigInt.asUintN(64, ret);
|
|
819
839
|
}
|
|
820
840
|
/**
|
|
@@ -869,13 +889,6 @@ class WasmBlock {
|
|
|
869
889
|
/**
|
|
870
890
|
* @returns {bigint}
|
|
871
891
|
*/
|
|
872
|
-
get nolan_falling_off_chain() {
|
|
873
|
-
const ret = wasm.wasmblock_nolan_falling_off_chain(this.__wbg_ptr);
|
|
874
|
-
return BigInt.asUintN(64, ret);
|
|
875
|
-
}
|
|
876
|
-
/**
|
|
877
|
-
* @returns {bigint}
|
|
878
|
-
*/
|
|
879
892
|
get avg_income() {
|
|
880
893
|
const ret = wasm.wasmblock_avg_income(this.__wbg_ptr);
|
|
881
894
|
return BigInt.asUintN(64, ret);
|
|
@@ -1276,7 +1289,7 @@ class WasmConsensusValues {
|
|
|
1276
1289
|
* @returns {number}
|
|
1277
1290
|
*/
|
|
1278
1291
|
get gt_index() {
|
|
1279
|
-
const ret = wasm.
|
|
1292
|
+
const ret = wasm.wasmblock_it_index(this.__wbg_ptr);
|
|
1280
1293
|
return ret >>> 0;
|
|
1281
1294
|
}
|
|
1282
1295
|
/**
|
|
@@ -1290,21 +1303,21 @@ class WasmConsensusValues {
|
|
|
1290
1303
|
* @returns {bigint}
|
|
1291
1304
|
*/
|
|
1292
1305
|
get expected_difficulty() {
|
|
1293
|
-
const ret = wasm.
|
|
1306
|
+
const ret = wasm.wasmblock_total_rebroadcast_fees_nolan(this.__wbg_ptr);
|
|
1294
1307
|
return BigInt.asUintN(64, ret);
|
|
1295
1308
|
}
|
|
1296
1309
|
/**
|
|
1297
1310
|
* @returns {bigint}
|
|
1298
1311
|
*/
|
|
1299
1312
|
get total_rebroadcast_slips() {
|
|
1300
|
-
const ret = wasm.
|
|
1313
|
+
const ret = wasm.wasmblock_burnfee(this.__wbg_ptr);
|
|
1301
1314
|
return BigInt.asUintN(64, ret);
|
|
1302
1315
|
}
|
|
1303
1316
|
/**
|
|
1304
1317
|
* @returns {bigint}
|
|
1305
1318
|
*/
|
|
1306
1319
|
get total_rebroadcast_nolan() {
|
|
1307
|
-
const ret = wasm.
|
|
1320
|
+
const ret = wasm.wasmblock_difficulty(this.__wbg_ptr);
|
|
1308
1321
|
return BigInt.asUintN(64, ret);
|
|
1309
1322
|
}
|
|
1310
1323
|
/**
|
|
@@ -1318,7 +1331,7 @@ class WasmConsensusValues {
|
|
|
1318
1331
|
* @returns {bigint}
|
|
1319
1332
|
*/
|
|
1320
1333
|
get total_rebroadcast_staking_payouts_nolan() {
|
|
1321
|
-
const ret = wasm.
|
|
1334
|
+
const ret = wasm.wasmblock_avg_nolan_rebroadcast_per_block(this.__wbg_ptr);
|
|
1322
1335
|
return BigInt.asUintN(64, ret);
|
|
1323
1336
|
}
|
|
1324
1337
|
/**
|
|
@@ -1331,13 +1344,6 @@ class WasmConsensusValues {
|
|
|
1331
1344
|
/**
|
|
1332
1345
|
* @returns {bigint}
|
|
1333
1346
|
*/
|
|
1334
|
-
get nolan_falling_off_chain() {
|
|
1335
|
-
const ret = wasm.wasmconsensusvalues_nolan_falling_off_chain(this.__wbg_ptr);
|
|
1336
|
-
return BigInt.asUintN(64, ret);
|
|
1337
|
-
}
|
|
1338
|
-
/**
|
|
1339
|
-
* @returns {bigint}
|
|
1340
|
-
*/
|
|
1341
1347
|
get avg_income() {
|
|
1342
1348
|
const ret = wasm.wasmconsensusvalues_avg_income(this.__wbg_ptr);
|
|
1343
1349
|
return BigInt.asUintN(64, ret);
|
|
@@ -1891,7 +1897,7 @@ class WasmTransaction {
|
|
|
1891
1897
|
* @returns {bigint}
|
|
1892
1898
|
*/
|
|
1893
1899
|
get timestamp() {
|
|
1894
|
-
const ret = wasm.
|
|
1900
|
+
const ret = wasm.wasmtransaction_get_timestamp(this.__wbg_ptr);
|
|
1895
1901
|
return BigInt.asUintN(64, ret);
|
|
1896
1902
|
}
|
|
1897
1903
|
/**
|
|
@@ -2232,18 +2238,13 @@ module.exports.__wbg_wasmtransaction_new = function(arg0) {
|
|
|
2232
2238
|
return addHeapObject(ret);
|
|
2233
2239
|
};
|
|
2234
2240
|
|
|
2235
|
-
module.exports.__wbg_wasmbalancesnapshot_new = function(arg0) {
|
|
2236
|
-
const ret = WasmBalanceSnapshot.__wrap(arg0);
|
|
2237
|
-
return addHeapObject(ret);
|
|
2238
|
-
};
|
|
2239
|
-
|
|
2240
2241
|
module.exports.__wbindgen_bigint_from_u64 = function(arg0) {
|
|
2241
2242
|
const ret = BigInt.asUintN(64, arg0);
|
|
2242
2243
|
return addHeapObject(ret);
|
|
2243
2244
|
};
|
|
2244
2245
|
|
|
2245
|
-
module.exports.
|
|
2246
|
-
const ret =
|
|
2246
|
+
module.exports.__wbg_wasmblockchain_new = function(arg0) {
|
|
2247
|
+
const ret = WasmBlockchain.__wrap(arg0);
|
|
2247
2248
|
return addHeapObject(ret);
|
|
2248
2249
|
};
|
|
2249
2250
|
|
|
@@ -2257,18 +2258,23 @@ module.exports.__wbg_wasmslip_new = function(arg0) {
|
|
|
2257
2258
|
return addHeapObject(ret);
|
|
2258
2259
|
};
|
|
2259
2260
|
|
|
2260
|
-
module.exports.
|
|
2261
|
-
const ret =
|
|
2261
|
+
module.exports.__wbg_wasmwalletslip_new = function(arg0) {
|
|
2262
|
+
const ret = WasmWalletSlip.__wrap(arg0);
|
|
2262
2263
|
return addHeapObject(ret);
|
|
2263
2264
|
};
|
|
2264
2265
|
|
|
2265
|
-
module.exports.
|
|
2266
|
-
const ret =
|
|
2266
|
+
module.exports.__wbg_wasmbalancesnapshot_new = function(arg0) {
|
|
2267
|
+
const ret = WasmBalanceSnapshot.__wrap(arg0);
|
|
2267
2268
|
return addHeapObject(ret);
|
|
2268
2269
|
};
|
|
2269
2270
|
|
|
2270
|
-
module.exports.
|
|
2271
|
-
const ret =
|
|
2271
|
+
module.exports.__wbg_wasmwallet_new = function(arg0) {
|
|
2272
|
+
const ret = WasmWallet.__wrap(arg0);
|
|
2273
|
+
return addHeapObject(ret);
|
|
2274
|
+
};
|
|
2275
|
+
|
|
2276
|
+
module.exports.__wbg_wasmblock_new = function(arg0) {
|
|
2277
|
+
const ret = WasmBlock.__wrap(arg0);
|
|
2272
2278
|
return addHeapObject(ret);
|
|
2273
2279
|
};
|
|
2274
2280
|
|
|
@@ -2281,41 +2287,20 @@ module.exports.__wbindgen_string_get = function(arg0, arg1) {
|
|
|
2281
2287
|
getInt32Memory0()[arg0 / 4 + 0] = ptr1;
|
|
2282
2288
|
};
|
|
2283
2289
|
|
|
2284
|
-
module.exports.__wbindgen_is_object = function(arg0) {
|
|
2285
|
-
const val = getObject(arg0);
|
|
2286
|
-
const ret = typeof(val) === 'object' && val !== null;
|
|
2287
|
-
return ret;
|
|
2288
|
-
};
|
|
2289
|
-
|
|
2290
|
-
module.exports.__wbindgen_is_undefined = function(arg0) {
|
|
2291
|
-
const ret = getObject(arg0) === undefined;
|
|
2292
|
-
return ret;
|
|
2293
|
-
};
|
|
2294
|
-
|
|
2295
|
-
module.exports.__wbindgen_in = function(arg0, arg1) {
|
|
2296
|
-
const ret = getObject(arg0) in getObject(arg1);
|
|
2297
|
-
return ret;
|
|
2298
|
-
};
|
|
2299
|
-
|
|
2300
|
-
module.exports.__wbindgen_error_new = function(arg0, arg1) {
|
|
2301
|
-
const ret = new Error(getStringFromWasm0(arg0, arg1));
|
|
2302
|
-
return addHeapObject(ret);
|
|
2303
|
-
};
|
|
2304
|
-
|
|
2305
2290
|
module.exports.__wbg_wasmconsensusvalues_new = function(arg0) {
|
|
2306
2291
|
const ret = WasmConsensusValues.__wrap(arg0);
|
|
2307
2292
|
return addHeapObject(ret);
|
|
2308
2293
|
};
|
|
2309
2294
|
|
|
2310
|
-
module.exports.
|
|
2295
|
+
module.exports.__wbg_sendmessage_6b0ad86b7c29c61e = function(arg0, arg1) {
|
|
2311
2296
|
MsgHandler.send_message(takeObject(arg0), getObject(arg1));
|
|
2312
2297
|
};
|
|
2313
2298
|
|
|
2314
|
-
module.exports.
|
|
2299
|
+
module.exports.__wbg_sendmessagetoall_87158161fc7dfd20 = function(arg0, arg1) {
|
|
2315
2300
|
MsgHandler.send_message_to_all(getObject(arg0), getObject(arg1));
|
|
2316
2301
|
};
|
|
2317
2302
|
|
|
2318
|
-
module.exports.
|
|
2303
|
+
module.exports.__wbg_connecttopeer_7df0b7c8da5d34db = function() { return handleError(function (arg0, arg1, arg2) {
|
|
2319
2304
|
let deferred0_0;
|
|
2320
2305
|
let deferred0_1;
|
|
2321
2306
|
try {
|
|
@@ -2328,12 +2313,12 @@ module.exports.__wbg_connecttopeer_cf9fc480c96432d5 = function() { return handle
|
|
|
2328
2313
|
}
|
|
2329
2314
|
}, arguments) };
|
|
2330
2315
|
|
|
2331
|
-
module.exports.
|
|
2316
|
+
module.exports.__wbg_disconnectfrompeer_df9c14251431d2b3 = function() { return handleError(function (arg0) {
|
|
2332
2317
|
const ret = MsgHandler.disconnect_from_peer(takeObject(arg0));
|
|
2333
2318
|
return addHeapObject(ret);
|
|
2334
2319
|
}, arguments) };
|
|
2335
2320
|
|
|
2336
|
-
module.exports.
|
|
2321
|
+
module.exports.__wbg_fetchblockfrompeer_19cd687aed4abc7b = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
|
|
2337
2322
|
let deferred0_0;
|
|
2338
2323
|
let deferred0_1;
|
|
2339
2324
|
try {
|
|
@@ -2346,7 +2331,7 @@ module.exports.__wbg_fetchblockfrompeer_beb702c2ac7a1383 = function() { return h
|
|
|
2346
2331
|
}
|
|
2347
2332
|
}, arguments) };
|
|
2348
2333
|
|
|
2349
|
-
module.exports.
|
|
2334
|
+
module.exports.__wbg_writevalue_ecf4ac5285a91469 = function(arg0, arg1, arg2) {
|
|
2350
2335
|
let deferred0_0;
|
|
2351
2336
|
let deferred0_1;
|
|
2352
2337
|
try {
|
|
@@ -2358,7 +2343,7 @@ module.exports.__wbg_writevalue_858b3a3794fbabf4 = function(arg0, arg1, arg2) {
|
|
|
2358
2343
|
}
|
|
2359
2344
|
};
|
|
2360
2345
|
|
|
2361
|
-
module.exports.
|
|
2346
|
+
module.exports.__wbg_appendvalue_fc982c07202b7757 = function(arg0, arg1, arg2) {
|
|
2362
2347
|
let deferred0_0;
|
|
2363
2348
|
let deferred0_1;
|
|
2364
2349
|
try {
|
|
@@ -2370,7 +2355,7 @@ module.exports.__wbg_appendvalue_3fa3914c63d94620 = function(arg0, arg1, arg2) {
|
|
|
2370
2355
|
}
|
|
2371
2356
|
};
|
|
2372
2357
|
|
|
2373
|
-
module.exports.
|
|
2358
|
+
module.exports.__wbg_flushdata_68e1546e87b93293 = function(arg0, arg1) {
|
|
2374
2359
|
let deferred0_0;
|
|
2375
2360
|
let deferred0_1;
|
|
2376
2361
|
try {
|
|
@@ -2382,7 +2367,7 @@ module.exports.__wbg_flushdata_001481339ab3b1e8 = function(arg0, arg1) {
|
|
|
2382
2367
|
}
|
|
2383
2368
|
};
|
|
2384
2369
|
|
|
2385
|
-
module.exports.
|
|
2370
|
+
module.exports.__wbg_readvalue_19e03f373e3bbfef = function() { return handleError(function (arg0, arg1) {
|
|
2386
2371
|
let deferred0_0;
|
|
2387
2372
|
let deferred0_1;
|
|
2388
2373
|
try {
|
|
@@ -2395,12 +2380,12 @@ module.exports.__wbg_readvalue_961833ec33afdae1 = function() { return handleErro
|
|
|
2395
2380
|
}
|
|
2396
2381
|
}, arguments) };
|
|
2397
2382
|
|
|
2398
|
-
module.exports.
|
|
2383
|
+
module.exports.__wbg_loadblockfilelist_06771287005e5934 = function() { return handleError(function () {
|
|
2399
2384
|
const ret = MsgHandler.load_block_file_list();
|
|
2400
2385
|
return addHeapObject(ret);
|
|
2401
2386
|
}, arguments) };
|
|
2402
2387
|
|
|
2403
|
-
module.exports.
|
|
2388
|
+
module.exports.__wbg_isexistingfile_8f14e1cea1ac2fc0 = function() { return handleError(function (arg0, arg1) {
|
|
2404
2389
|
let deferred0_0;
|
|
2405
2390
|
let deferred0_1;
|
|
2406
2391
|
try {
|
|
@@ -2413,7 +2398,7 @@ module.exports.__wbg_isexistingfile_1195edd3c769e6cd = function() { return handl
|
|
|
2413
2398
|
}
|
|
2414
2399
|
}, arguments) };
|
|
2415
2400
|
|
|
2416
|
-
module.exports.
|
|
2401
|
+
module.exports.__wbg_removevalue_569ddb06340909fa = function() { return handleError(function (arg0, arg1) {
|
|
2417
2402
|
let deferred0_0;
|
|
2418
2403
|
let deferred0_1;
|
|
2419
2404
|
try {
|
|
@@ -2426,7 +2411,7 @@ module.exports.__wbg_removevalue_cbfa7044bf726cbf = function() { return handleEr
|
|
|
2426
2411
|
}
|
|
2427
2412
|
}, arguments) };
|
|
2428
2413
|
|
|
2429
|
-
module.exports.
|
|
2414
|
+
module.exports.__wbg_ensureblockdirectoryexists_f3555cd01725a0a8 = function() { return handleError(function (arg0, arg1) {
|
|
2430
2415
|
let deferred0_0;
|
|
2431
2416
|
let deferred0_1;
|
|
2432
2417
|
try {
|
|
@@ -2438,19 +2423,19 @@ module.exports.__wbg_ensureblockdirectoryexists_9ab23c529877f183 = function() {
|
|
|
2438
2423
|
}
|
|
2439
2424
|
}, arguments) };
|
|
2440
2425
|
|
|
2441
|
-
module.exports.
|
|
2442
|
-
MsgHandler.process_api_call(takeObject(arg0), arg1 >>> 0,
|
|
2426
|
+
module.exports.__wbg_processapicall_15a53848d5377955 = function(arg0, arg1, arg2) {
|
|
2427
|
+
MsgHandler.process_api_call(takeObject(arg0), arg1 >>> 0, takeObject(arg2));
|
|
2443
2428
|
};
|
|
2444
2429
|
|
|
2445
|
-
module.exports.
|
|
2446
|
-
MsgHandler.process_api_success(takeObject(arg0), arg1 >>> 0,
|
|
2430
|
+
module.exports.__wbg_processapisuccess_78d716af406160e1 = function(arg0, arg1, arg2) {
|
|
2431
|
+
MsgHandler.process_api_success(takeObject(arg0), arg1 >>> 0, takeObject(arg2));
|
|
2447
2432
|
};
|
|
2448
2433
|
|
|
2449
|
-
module.exports.
|
|
2450
|
-
MsgHandler.process_api_error(takeObject(arg0), arg1 >>> 0,
|
|
2434
|
+
module.exports.__wbg_processapierror_957c88011799d859 = function(arg0, arg1, arg2) {
|
|
2435
|
+
MsgHandler.process_api_error(takeObject(arg0), arg1 >>> 0, takeObject(arg2));
|
|
2451
2436
|
};
|
|
2452
2437
|
|
|
2453
|
-
module.exports.
|
|
2438
|
+
module.exports.__wbg_sendinterfaceevent_2558a262a3112215 = function(arg0, arg1, arg2, arg3, arg4) {
|
|
2454
2439
|
let deferred0_0;
|
|
2455
2440
|
let deferred0_1;
|
|
2456
2441
|
let deferred1_0;
|
|
@@ -2460,64 +2445,89 @@ module.exports.__wbg_sendinterfaceevent_2fa472ddf29a9566 = function(arg0, arg1,
|
|
|
2460
2445
|
deferred0_1 = arg1;
|
|
2461
2446
|
deferred1_0 = arg3;
|
|
2462
2447
|
deferred1_1 = arg4;
|
|
2463
|
-
MsgHandler.send_interface_event(getStringFromWasm0(arg0, arg1),
|
|
2448
|
+
MsgHandler.send_interface_event(getStringFromWasm0(arg0, arg1), takeObject(arg2), getStringFromWasm0(arg3, arg4));
|
|
2464
2449
|
} finally {
|
|
2465
2450
|
wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
|
|
2466
2451
|
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
2467
2452
|
}
|
|
2468
2453
|
};
|
|
2469
2454
|
|
|
2470
|
-
module.exports.
|
|
2455
|
+
module.exports.__wbg_sendblocksuccess_7d7d2f2d156053f8 = function(arg0, arg1, arg2) {
|
|
2471
2456
|
let deferred0_0;
|
|
2472
2457
|
let deferred0_1;
|
|
2473
2458
|
try {
|
|
2474
2459
|
deferred0_0 = arg0;
|
|
2475
2460
|
deferred0_1 = arg1;
|
|
2476
|
-
MsgHandler.send_block_success(getStringFromWasm0(arg0, arg1),
|
|
2461
|
+
MsgHandler.send_block_success(getStringFromWasm0(arg0, arg1), takeObject(arg2));
|
|
2477
2462
|
} finally {
|
|
2478
2463
|
wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
|
|
2479
2464
|
}
|
|
2480
2465
|
};
|
|
2481
2466
|
|
|
2482
|
-
module.exports.
|
|
2467
|
+
module.exports.__wbg_sendwalletupdate_011131ae87fcc26a = function() {
|
|
2483
2468
|
MsgHandler.send_wallet_update();
|
|
2484
2469
|
};
|
|
2485
2470
|
|
|
2486
|
-
module.exports.
|
|
2471
|
+
module.exports.__wbg_sendnewversionalert_5eb67e3a745c1c5a = function(arg0, arg1, arg2) {
|
|
2487
2472
|
let deferred0_0;
|
|
2488
2473
|
let deferred0_1;
|
|
2489
2474
|
try {
|
|
2490
2475
|
deferred0_0 = arg0;
|
|
2491
2476
|
deferred0_1 = arg1;
|
|
2492
|
-
MsgHandler.send_new_version_alert(getStringFromWasm0(arg0, arg1),
|
|
2477
|
+
MsgHandler.send_new_version_alert(getStringFromWasm0(arg0, arg1), takeObject(arg2));
|
|
2493
2478
|
} finally {
|
|
2494
2479
|
wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
|
|
2495
2480
|
}
|
|
2496
2481
|
};
|
|
2497
2482
|
|
|
2498
|
-
module.exports.
|
|
2483
|
+
module.exports.__wbg_sendblockfetchstatusevent_3fbd875ece947b89 = function(arg0) {
|
|
2484
|
+
MsgHandler.send_block_fetch_status_event(BigInt.asUintN(64, arg0));
|
|
2485
|
+
};
|
|
2486
|
+
|
|
2487
|
+
module.exports.__wbg_savewallet_83a9346922528210 = function() {
|
|
2499
2488
|
MsgHandler.save_wallet();
|
|
2500
2489
|
};
|
|
2501
2490
|
|
|
2502
|
-
module.exports.
|
|
2491
|
+
module.exports.__wbg_loadwallet_7da8be590ae3e7d2 = function() {
|
|
2503
2492
|
MsgHandler.load_wallet();
|
|
2504
2493
|
};
|
|
2505
2494
|
|
|
2506
|
-
module.exports.
|
|
2495
|
+
module.exports.__wbg_getmyservices_08d10cec31a6c94e = function() {
|
|
2507
2496
|
const ret = MsgHandler.get_my_services();
|
|
2508
2497
|
_assertClass(ret, WasmPeerServiceList);
|
|
2509
2498
|
var ptr1 = ret.__destroy_into_raw();
|
|
2510
2499
|
return ptr1;
|
|
2511
2500
|
};
|
|
2512
2501
|
|
|
2502
|
+
module.exports.__wbg_wasmhop_new = function(arg0) {
|
|
2503
|
+
const ret = WasmHop.__wrap(arg0);
|
|
2504
|
+
return addHeapObject(ret);
|
|
2505
|
+
};
|
|
2506
|
+
|
|
2507
|
+
module.exports.__wbindgen_error_new = function(arg0, arg1) {
|
|
2508
|
+
const ret = new Error(getStringFromWasm0(arg0, arg1));
|
|
2509
|
+
return addHeapObject(ret);
|
|
2510
|
+
};
|
|
2511
|
+
|
|
2513
2512
|
module.exports.__wbg_wasmpeerservice_new = function(arg0) {
|
|
2514
2513
|
const ret = WasmPeerService.__wrap(arg0);
|
|
2515
2514
|
return addHeapObject(ret);
|
|
2516
2515
|
};
|
|
2517
2516
|
|
|
2518
|
-
module.exports.
|
|
2519
|
-
const
|
|
2520
|
-
|
|
2517
|
+
module.exports.__wbindgen_is_object = function(arg0) {
|
|
2518
|
+
const val = getObject(arg0);
|
|
2519
|
+
const ret = typeof(val) === 'object' && val !== null;
|
|
2520
|
+
return ret;
|
|
2521
|
+
};
|
|
2522
|
+
|
|
2523
|
+
module.exports.__wbindgen_is_undefined = function(arg0) {
|
|
2524
|
+
const ret = getObject(arg0) === undefined;
|
|
2525
|
+
return ret;
|
|
2526
|
+
};
|
|
2527
|
+
|
|
2528
|
+
module.exports.__wbindgen_in = function(arg0, arg1) {
|
|
2529
|
+
const ret = getObject(arg0) in getObject(arg1);
|
|
2530
|
+
return ret;
|
|
2521
2531
|
};
|
|
2522
2532
|
|
|
2523
2533
|
module.exports.__wbindgen_jsval_loose_eq = function(arg0, arg1) {
|
|
@@ -2767,7 +2777,7 @@ module.exports.__wbg_new_81740750da40724f = function(arg0, arg1) {
|
|
|
2767
2777
|
const a = state0.a;
|
|
2768
2778
|
state0.a = 0;
|
|
2769
2779
|
try {
|
|
2770
|
-
return
|
|
2780
|
+
return __wbg_adapter_381(a, state0.b, arg0, arg1);
|
|
2771
2781
|
} finally {
|
|
2772
2782
|
state0.a = a;
|
|
2773
2783
|
}
|
|
@@ -2865,7 +2875,7 @@ module.exports.__wbindgen_memory = function() {
|
|
|
2865
2875
|
return addHeapObject(ret);
|
|
2866
2876
|
};
|
|
2867
2877
|
|
|
2868
|
-
module.exports.
|
|
2878
|
+
module.exports.__wbindgen_closure_wrapper1304 = function(arg0, arg1, arg2) {
|
|
2869
2879
|
const ret = makeMutClosure(arg0, arg1, 458, __wbg_adapter_38);
|
|
2870
2880
|
return addHeapObject(ret);
|
|
2871
2881
|
};
|
package/pkg/node/index_bg.wasm
CHANGED
|
Binary file
|