@trustwallet/wallet-core 3.0.4 → 3.0.5
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/generated/core_proto.d.ts +668 -102
- package/dist/generated/core_proto.js +1774 -163
- package/dist/lib/wallet-core.js +148 -160
- package/dist/lib/wallet-core.wasm +0 -0
- package/dist/src/wallet-core.d.ts +546 -542
- package/package.json +1 -1
@@ -2466,6 +2466,1748 @@
|
|
2466
2466
|
return Algorand;
|
2467
2467
|
})();
|
2468
2468
|
|
2469
|
+
TW.Aptos = (function() {
|
2470
|
+
|
2471
|
+
/**
|
2472
|
+
* Namespace Aptos.
|
2473
|
+
* @memberof TW
|
2474
|
+
* @namespace
|
2475
|
+
*/
|
2476
|
+
var Aptos = {};
|
2477
|
+
|
2478
|
+
Aptos.Proto = (function() {
|
2479
|
+
|
2480
|
+
/**
|
2481
|
+
* Namespace Proto.
|
2482
|
+
* @memberof TW.Aptos
|
2483
|
+
* @namespace
|
2484
|
+
*/
|
2485
|
+
var Proto = {};
|
2486
|
+
|
2487
|
+
Proto.TransferMessage = (function() {
|
2488
|
+
|
2489
|
+
/**
|
2490
|
+
* Properties of a TransferMessage.
|
2491
|
+
* @memberof TW.Aptos.Proto
|
2492
|
+
* @interface ITransferMessage
|
2493
|
+
* @property {string|null} [to] TransferMessage to
|
2494
|
+
* @property {Long|null} [amount] TransferMessage amount
|
2495
|
+
*/
|
2496
|
+
|
2497
|
+
/**
|
2498
|
+
* Constructs a new TransferMessage.
|
2499
|
+
* @memberof TW.Aptos.Proto
|
2500
|
+
* @classdesc Represents a TransferMessage.
|
2501
|
+
* @implements ITransferMessage
|
2502
|
+
* @constructor
|
2503
|
+
* @param {TW.Aptos.Proto.ITransferMessage=} [properties] Properties to set
|
2504
|
+
*/
|
2505
|
+
function TransferMessage(properties) {
|
2506
|
+
if (properties)
|
2507
|
+
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
|
2508
|
+
if (properties[keys[i]] != null)
|
2509
|
+
this[keys[i]] = properties[keys[i]];
|
2510
|
+
}
|
2511
|
+
|
2512
|
+
/**
|
2513
|
+
* TransferMessage to.
|
2514
|
+
* @member {string} to
|
2515
|
+
* @memberof TW.Aptos.Proto.TransferMessage
|
2516
|
+
* @instance
|
2517
|
+
*/
|
2518
|
+
TransferMessage.prototype.to = "";
|
2519
|
+
|
2520
|
+
/**
|
2521
|
+
* TransferMessage amount.
|
2522
|
+
* @member {Long} amount
|
2523
|
+
* @memberof TW.Aptos.Proto.TransferMessage
|
2524
|
+
* @instance
|
2525
|
+
*/
|
2526
|
+
TransferMessage.prototype.amount = $util.Long ? $util.Long.fromBits(0,0,true) : 0;
|
2527
|
+
|
2528
|
+
/**
|
2529
|
+
* Creates a new TransferMessage instance using the specified properties.
|
2530
|
+
* @function create
|
2531
|
+
* @memberof TW.Aptos.Proto.TransferMessage
|
2532
|
+
* @static
|
2533
|
+
* @param {TW.Aptos.Proto.ITransferMessage=} [properties] Properties to set
|
2534
|
+
* @returns {TW.Aptos.Proto.TransferMessage} TransferMessage instance
|
2535
|
+
*/
|
2536
|
+
TransferMessage.create = function create(properties) {
|
2537
|
+
return new TransferMessage(properties);
|
2538
|
+
};
|
2539
|
+
|
2540
|
+
/**
|
2541
|
+
* Encodes the specified TransferMessage message. Does not implicitly {@link TW.Aptos.Proto.TransferMessage.verify|verify} messages.
|
2542
|
+
* @function encode
|
2543
|
+
* @memberof TW.Aptos.Proto.TransferMessage
|
2544
|
+
* @static
|
2545
|
+
* @param {TW.Aptos.Proto.ITransferMessage} message TransferMessage message or plain object to encode
|
2546
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
2547
|
+
* @returns {$protobuf.Writer} Writer
|
2548
|
+
*/
|
2549
|
+
TransferMessage.encode = function encode(message, writer) {
|
2550
|
+
if (!writer)
|
2551
|
+
writer = $Writer.create();
|
2552
|
+
if (message.to != null && Object.hasOwnProperty.call(message, "to"))
|
2553
|
+
writer.uint32(/* id 1, wireType 2 =*/10).string(message.to);
|
2554
|
+
if (message.amount != null && Object.hasOwnProperty.call(message, "amount"))
|
2555
|
+
writer.uint32(/* id 2, wireType 0 =*/16).uint64(message.amount);
|
2556
|
+
return writer;
|
2557
|
+
};
|
2558
|
+
|
2559
|
+
/**
|
2560
|
+
* Decodes a TransferMessage message from the specified reader or buffer.
|
2561
|
+
* @function decode
|
2562
|
+
* @memberof TW.Aptos.Proto.TransferMessage
|
2563
|
+
* @static
|
2564
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
2565
|
+
* @param {number} [length] Message length if known beforehand
|
2566
|
+
* @returns {TW.Aptos.Proto.TransferMessage} TransferMessage
|
2567
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
2568
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
2569
|
+
*/
|
2570
|
+
TransferMessage.decode = function decode(reader, length) {
|
2571
|
+
if (!(reader instanceof $Reader))
|
2572
|
+
reader = $Reader.create(reader);
|
2573
|
+
var end = length === undefined ? reader.len : reader.pos + length, message = new $root.TW.Aptos.Proto.TransferMessage();
|
2574
|
+
while (reader.pos < end) {
|
2575
|
+
var tag = reader.uint32();
|
2576
|
+
switch (tag >>> 3) {
|
2577
|
+
case 1:
|
2578
|
+
message.to = reader.string();
|
2579
|
+
break;
|
2580
|
+
case 2:
|
2581
|
+
message.amount = reader.uint64();
|
2582
|
+
break;
|
2583
|
+
default:
|
2584
|
+
reader.skipType(tag & 7);
|
2585
|
+
break;
|
2586
|
+
}
|
2587
|
+
}
|
2588
|
+
return message;
|
2589
|
+
};
|
2590
|
+
|
2591
|
+
/**
|
2592
|
+
* Verifies a TransferMessage message.
|
2593
|
+
* @function verify
|
2594
|
+
* @memberof TW.Aptos.Proto.TransferMessage
|
2595
|
+
* @static
|
2596
|
+
* @param {Object.<string,*>} message Plain object to verify
|
2597
|
+
* @returns {string|null} `null` if valid, otherwise the reason why it is not
|
2598
|
+
*/
|
2599
|
+
TransferMessage.verify = function verify(message) {
|
2600
|
+
if (typeof message !== "object" || message === null)
|
2601
|
+
return "object expected";
|
2602
|
+
if (message.to != null && message.hasOwnProperty("to"))
|
2603
|
+
if (!$util.isString(message.to))
|
2604
|
+
return "to: string expected";
|
2605
|
+
if (message.amount != null && message.hasOwnProperty("amount"))
|
2606
|
+
if (!$util.isInteger(message.amount) && !(message.amount && $util.isInteger(message.amount.low) && $util.isInteger(message.amount.high)))
|
2607
|
+
return "amount: integer|Long expected";
|
2608
|
+
return null;
|
2609
|
+
};
|
2610
|
+
|
2611
|
+
/**
|
2612
|
+
* Creates a TransferMessage message from a plain object. Also converts values to their respective internal types.
|
2613
|
+
* @function fromObject
|
2614
|
+
* @memberof TW.Aptos.Proto.TransferMessage
|
2615
|
+
* @static
|
2616
|
+
* @param {Object.<string,*>} object Plain object
|
2617
|
+
* @returns {TW.Aptos.Proto.TransferMessage} TransferMessage
|
2618
|
+
*/
|
2619
|
+
TransferMessage.fromObject = function fromObject(object) {
|
2620
|
+
if (object instanceof $root.TW.Aptos.Proto.TransferMessage)
|
2621
|
+
return object;
|
2622
|
+
var message = new $root.TW.Aptos.Proto.TransferMessage();
|
2623
|
+
if (object.to != null)
|
2624
|
+
message.to = String(object.to);
|
2625
|
+
if (object.amount != null)
|
2626
|
+
if ($util.Long)
|
2627
|
+
(message.amount = $util.Long.fromValue(object.amount)).unsigned = true;
|
2628
|
+
else if (typeof object.amount === "string")
|
2629
|
+
message.amount = parseInt(object.amount, 10);
|
2630
|
+
else if (typeof object.amount === "number")
|
2631
|
+
message.amount = object.amount;
|
2632
|
+
else if (typeof object.amount === "object")
|
2633
|
+
message.amount = new $util.LongBits(object.amount.low >>> 0, object.amount.high >>> 0).toNumber(true);
|
2634
|
+
return message;
|
2635
|
+
};
|
2636
|
+
|
2637
|
+
/**
|
2638
|
+
* Creates a plain object from a TransferMessage message. Also converts values to other types if specified.
|
2639
|
+
* @function toObject
|
2640
|
+
* @memberof TW.Aptos.Proto.TransferMessage
|
2641
|
+
* @static
|
2642
|
+
* @param {TW.Aptos.Proto.TransferMessage} message TransferMessage
|
2643
|
+
* @param {$protobuf.IConversionOptions} [options] Conversion options
|
2644
|
+
* @returns {Object.<string,*>} Plain object
|
2645
|
+
*/
|
2646
|
+
TransferMessage.toObject = function toObject(message, options) {
|
2647
|
+
if (!options)
|
2648
|
+
options = {};
|
2649
|
+
var object = {};
|
2650
|
+
if (options.defaults) {
|
2651
|
+
object.to = "";
|
2652
|
+
if ($util.Long) {
|
2653
|
+
var long = new $util.Long(0, 0, true);
|
2654
|
+
object.amount = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long;
|
2655
|
+
} else
|
2656
|
+
object.amount = options.longs === String ? "0" : 0;
|
2657
|
+
}
|
2658
|
+
if (message.to != null && message.hasOwnProperty("to"))
|
2659
|
+
object.to = message.to;
|
2660
|
+
if (message.amount != null && message.hasOwnProperty("amount"))
|
2661
|
+
if (typeof message.amount === "number")
|
2662
|
+
object.amount = options.longs === String ? String(message.amount) : message.amount;
|
2663
|
+
else
|
2664
|
+
object.amount = options.longs === String ? $util.Long.prototype.toString.call(message.amount) : options.longs === Number ? new $util.LongBits(message.amount.low >>> 0, message.amount.high >>> 0).toNumber(true) : message.amount;
|
2665
|
+
return object;
|
2666
|
+
};
|
2667
|
+
|
2668
|
+
/**
|
2669
|
+
* Converts this TransferMessage to JSON.
|
2670
|
+
* @function toJSON
|
2671
|
+
* @memberof TW.Aptos.Proto.TransferMessage
|
2672
|
+
* @instance
|
2673
|
+
* @returns {Object.<string,*>} JSON object
|
2674
|
+
*/
|
2675
|
+
TransferMessage.prototype.toJSON = function toJSON() {
|
2676
|
+
return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
|
2677
|
+
};
|
2678
|
+
|
2679
|
+
return TransferMessage;
|
2680
|
+
})();
|
2681
|
+
|
2682
|
+
Proto.StructTag = (function() {
|
2683
|
+
|
2684
|
+
/**
|
2685
|
+
* Properties of a StructTag.
|
2686
|
+
* @memberof TW.Aptos.Proto
|
2687
|
+
* @interface IStructTag
|
2688
|
+
* @property {string|null} [accountAddress] StructTag accountAddress
|
2689
|
+
* @property {string|null} [module] StructTag module
|
2690
|
+
* @property {string|null} [name] StructTag name
|
2691
|
+
*/
|
2692
|
+
|
2693
|
+
/**
|
2694
|
+
* Constructs a new StructTag.
|
2695
|
+
* @memberof TW.Aptos.Proto
|
2696
|
+
* @classdesc Represents a StructTag.
|
2697
|
+
* @implements IStructTag
|
2698
|
+
* @constructor
|
2699
|
+
* @param {TW.Aptos.Proto.IStructTag=} [properties] Properties to set
|
2700
|
+
*/
|
2701
|
+
function StructTag(properties) {
|
2702
|
+
if (properties)
|
2703
|
+
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
|
2704
|
+
if (properties[keys[i]] != null)
|
2705
|
+
this[keys[i]] = properties[keys[i]];
|
2706
|
+
}
|
2707
|
+
|
2708
|
+
/**
|
2709
|
+
* StructTag accountAddress.
|
2710
|
+
* @member {string} accountAddress
|
2711
|
+
* @memberof TW.Aptos.Proto.StructTag
|
2712
|
+
* @instance
|
2713
|
+
*/
|
2714
|
+
StructTag.prototype.accountAddress = "";
|
2715
|
+
|
2716
|
+
/**
|
2717
|
+
* StructTag module.
|
2718
|
+
* @member {string} module
|
2719
|
+
* @memberof TW.Aptos.Proto.StructTag
|
2720
|
+
* @instance
|
2721
|
+
*/
|
2722
|
+
StructTag.prototype.module = "";
|
2723
|
+
|
2724
|
+
/**
|
2725
|
+
* StructTag name.
|
2726
|
+
* @member {string} name
|
2727
|
+
* @memberof TW.Aptos.Proto.StructTag
|
2728
|
+
* @instance
|
2729
|
+
*/
|
2730
|
+
StructTag.prototype.name = "";
|
2731
|
+
|
2732
|
+
/**
|
2733
|
+
* Creates a new StructTag instance using the specified properties.
|
2734
|
+
* @function create
|
2735
|
+
* @memberof TW.Aptos.Proto.StructTag
|
2736
|
+
* @static
|
2737
|
+
* @param {TW.Aptos.Proto.IStructTag=} [properties] Properties to set
|
2738
|
+
* @returns {TW.Aptos.Proto.StructTag} StructTag instance
|
2739
|
+
*/
|
2740
|
+
StructTag.create = function create(properties) {
|
2741
|
+
return new StructTag(properties);
|
2742
|
+
};
|
2743
|
+
|
2744
|
+
/**
|
2745
|
+
* Encodes the specified StructTag message. Does not implicitly {@link TW.Aptos.Proto.StructTag.verify|verify} messages.
|
2746
|
+
* @function encode
|
2747
|
+
* @memberof TW.Aptos.Proto.StructTag
|
2748
|
+
* @static
|
2749
|
+
* @param {TW.Aptos.Proto.IStructTag} message StructTag message or plain object to encode
|
2750
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
2751
|
+
* @returns {$protobuf.Writer} Writer
|
2752
|
+
*/
|
2753
|
+
StructTag.encode = function encode(message, writer) {
|
2754
|
+
if (!writer)
|
2755
|
+
writer = $Writer.create();
|
2756
|
+
if (message.accountAddress != null && Object.hasOwnProperty.call(message, "accountAddress"))
|
2757
|
+
writer.uint32(/* id 1, wireType 2 =*/10).string(message.accountAddress);
|
2758
|
+
if (message.module != null && Object.hasOwnProperty.call(message, "module"))
|
2759
|
+
writer.uint32(/* id 2, wireType 2 =*/18).string(message.module);
|
2760
|
+
if (message.name != null && Object.hasOwnProperty.call(message, "name"))
|
2761
|
+
writer.uint32(/* id 3, wireType 2 =*/26).string(message.name);
|
2762
|
+
return writer;
|
2763
|
+
};
|
2764
|
+
|
2765
|
+
/**
|
2766
|
+
* Decodes a StructTag message from the specified reader or buffer.
|
2767
|
+
* @function decode
|
2768
|
+
* @memberof TW.Aptos.Proto.StructTag
|
2769
|
+
* @static
|
2770
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
2771
|
+
* @param {number} [length] Message length if known beforehand
|
2772
|
+
* @returns {TW.Aptos.Proto.StructTag} StructTag
|
2773
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
2774
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
2775
|
+
*/
|
2776
|
+
StructTag.decode = function decode(reader, length) {
|
2777
|
+
if (!(reader instanceof $Reader))
|
2778
|
+
reader = $Reader.create(reader);
|
2779
|
+
var end = length === undefined ? reader.len : reader.pos + length, message = new $root.TW.Aptos.Proto.StructTag();
|
2780
|
+
while (reader.pos < end) {
|
2781
|
+
var tag = reader.uint32();
|
2782
|
+
switch (tag >>> 3) {
|
2783
|
+
case 1:
|
2784
|
+
message.accountAddress = reader.string();
|
2785
|
+
break;
|
2786
|
+
case 2:
|
2787
|
+
message.module = reader.string();
|
2788
|
+
break;
|
2789
|
+
case 3:
|
2790
|
+
message.name = reader.string();
|
2791
|
+
break;
|
2792
|
+
default:
|
2793
|
+
reader.skipType(tag & 7);
|
2794
|
+
break;
|
2795
|
+
}
|
2796
|
+
}
|
2797
|
+
return message;
|
2798
|
+
};
|
2799
|
+
|
2800
|
+
/**
|
2801
|
+
* Verifies a StructTag message.
|
2802
|
+
* @function verify
|
2803
|
+
* @memberof TW.Aptos.Proto.StructTag
|
2804
|
+
* @static
|
2805
|
+
* @param {Object.<string,*>} message Plain object to verify
|
2806
|
+
* @returns {string|null} `null` if valid, otherwise the reason why it is not
|
2807
|
+
*/
|
2808
|
+
StructTag.verify = function verify(message) {
|
2809
|
+
if (typeof message !== "object" || message === null)
|
2810
|
+
return "object expected";
|
2811
|
+
if (message.accountAddress != null && message.hasOwnProperty("accountAddress"))
|
2812
|
+
if (!$util.isString(message.accountAddress))
|
2813
|
+
return "accountAddress: string expected";
|
2814
|
+
if (message.module != null && message.hasOwnProperty("module"))
|
2815
|
+
if (!$util.isString(message.module))
|
2816
|
+
return "module: string expected";
|
2817
|
+
if (message.name != null && message.hasOwnProperty("name"))
|
2818
|
+
if (!$util.isString(message.name))
|
2819
|
+
return "name: string expected";
|
2820
|
+
return null;
|
2821
|
+
};
|
2822
|
+
|
2823
|
+
/**
|
2824
|
+
* Creates a StructTag message from a plain object. Also converts values to their respective internal types.
|
2825
|
+
* @function fromObject
|
2826
|
+
* @memberof TW.Aptos.Proto.StructTag
|
2827
|
+
* @static
|
2828
|
+
* @param {Object.<string,*>} object Plain object
|
2829
|
+
* @returns {TW.Aptos.Proto.StructTag} StructTag
|
2830
|
+
*/
|
2831
|
+
StructTag.fromObject = function fromObject(object) {
|
2832
|
+
if (object instanceof $root.TW.Aptos.Proto.StructTag)
|
2833
|
+
return object;
|
2834
|
+
var message = new $root.TW.Aptos.Proto.StructTag();
|
2835
|
+
if (object.accountAddress != null)
|
2836
|
+
message.accountAddress = String(object.accountAddress);
|
2837
|
+
if (object.module != null)
|
2838
|
+
message.module = String(object.module);
|
2839
|
+
if (object.name != null)
|
2840
|
+
message.name = String(object.name);
|
2841
|
+
return message;
|
2842
|
+
};
|
2843
|
+
|
2844
|
+
/**
|
2845
|
+
* Creates a plain object from a StructTag message. Also converts values to other types if specified.
|
2846
|
+
* @function toObject
|
2847
|
+
* @memberof TW.Aptos.Proto.StructTag
|
2848
|
+
* @static
|
2849
|
+
* @param {TW.Aptos.Proto.StructTag} message StructTag
|
2850
|
+
* @param {$protobuf.IConversionOptions} [options] Conversion options
|
2851
|
+
* @returns {Object.<string,*>} Plain object
|
2852
|
+
*/
|
2853
|
+
StructTag.toObject = function toObject(message, options) {
|
2854
|
+
if (!options)
|
2855
|
+
options = {};
|
2856
|
+
var object = {};
|
2857
|
+
if (options.defaults) {
|
2858
|
+
object.accountAddress = "";
|
2859
|
+
object.module = "";
|
2860
|
+
object.name = "";
|
2861
|
+
}
|
2862
|
+
if (message.accountAddress != null && message.hasOwnProperty("accountAddress"))
|
2863
|
+
object.accountAddress = message.accountAddress;
|
2864
|
+
if (message.module != null && message.hasOwnProperty("module"))
|
2865
|
+
object.module = message.module;
|
2866
|
+
if (message.name != null && message.hasOwnProperty("name"))
|
2867
|
+
object.name = message.name;
|
2868
|
+
return object;
|
2869
|
+
};
|
2870
|
+
|
2871
|
+
/**
|
2872
|
+
* Converts this StructTag to JSON.
|
2873
|
+
* @function toJSON
|
2874
|
+
* @memberof TW.Aptos.Proto.StructTag
|
2875
|
+
* @instance
|
2876
|
+
* @returns {Object.<string,*>} JSON object
|
2877
|
+
*/
|
2878
|
+
StructTag.prototype.toJSON = function toJSON() {
|
2879
|
+
return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
|
2880
|
+
};
|
2881
|
+
|
2882
|
+
return StructTag;
|
2883
|
+
})();
|
2884
|
+
|
2885
|
+
Proto.TokenTransferMessage = (function() {
|
2886
|
+
|
2887
|
+
/**
|
2888
|
+
* Properties of a TokenTransferMessage.
|
2889
|
+
* @memberof TW.Aptos.Proto
|
2890
|
+
* @interface ITokenTransferMessage
|
2891
|
+
* @property {string|null} [to] TokenTransferMessage to
|
2892
|
+
* @property {Long|null} [amount] TokenTransferMessage amount
|
2893
|
+
* @property {TW.Aptos.Proto.IStructTag|null} ["function"] TokenTransferMessage function
|
2894
|
+
*/
|
2895
|
+
|
2896
|
+
/**
|
2897
|
+
* Constructs a new TokenTransferMessage.
|
2898
|
+
* @memberof TW.Aptos.Proto
|
2899
|
+
* @classdesc Represents a TokenTransferMessage.
|
2900
|
+
* @implements ITokenTransferMessage
|
2901
|
+
* @constructor
|
2902
|
+
* @param {TW.Aptos.Proto.ITokenTransferMessage=} [properties] Properties to set
|
2903
|
+
*/
|
2904
|
+
function TokenTransferMessage(properties) {
|
2905
|
+
if (properties)
|
2906
|
+
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
|
2907
|
+
if (properties[keys[i]] != null)
|
2908
|
+
this[keys[i]] = properties[keys[i]];
|
2909
|
+
}
|
2910
|
+
|
2911
|
+
/**
|
2912
|
+
* TokenTransferMessage to.
|
2913
|
+
* @member {string} to
|
2914
|
+
* @memberof TW.Aptos.Proto.TokenTransferMessage
|
2915
|
+
* @instance
|
2916
|
+
*/
|
2917
|
+
TokenTransferMessage.prototype.to = "";
|
2918
|
+
|
2919
|
+
/**
|
2920
|
+
* TokenTransferMessage amount.
|
2921
|
+
* @member {Long} amount
|
2922
|
+
* @memberof TW.Aptos.Proto.TokenTransferMessage
|
2923
|
+
* @instance
|
2924
|
+
*/
|
2925
|
+
TokenTransferMessage.prototype.amount = $util.Long ? $util.Long.fromBits(0,0,true) : 0;
|
2926
|
+
|
2927
|
+
/**
|
2928
|
+
* TokenTransferMessage function.
|
2929
|
+
* @member {TW.Aptos.Proto.IStructTag|null|undefined} function
|
2930
|
+
* @memberof TW.Aptos.Proto.TokenTransferMessage
|
2931
|
+
* @instance
|
2932
|
+
*/
|
2933
|
+
TokenTransferMessage.prototype["function"] = null;
|
2934
|
+
|
2935
|
+
/**
|
2936
|
+
* Creates a new TokenTransferMessage instance using the specified properties.
|
2937
|
+
* @function create
|
2938
|
+
* @memberof TW.Aptos.Proto.TokenTransferMessage
|
2939
|
+
* @static
|
2940
|
+
* @param {TW.Aptos.Proto.ITokenTransferMessage=} [properties] Properties to set
|
2941
|
+
* @returns {TW.Aptos.Proto.TokenTransferMessage} TokenTransferMessage instance
|
2942
|
+
*/
|
2943
|
+
TokenTransferMessage.create = function create(properties) {
|
2944
|
+
return new TokenTransferMessage(properties);
|
2945
|
+
};
|
2946
|
+
|
2947
|
+
/**
|
2948
|
+
* Encodes the specified TokenTransferMessage message. Does not implicitly {@link TW.Aptos.Proto.TokenTransferMessage.verify|verify} messages.
|
2949
|
+
* @function encode
|
2950
|
+
* @memberof TW.Aptos.Proto.TokenTransferMessage
|
2951
|
+
* @static
|
2952
|
+
* @param {TW.Aptos.Proto.ITokenTransferMessage} message TokenTransferMessage message or plain object to encode
|
2953
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
2954
|
+
* @returns {$protobuf.Writer} Writer
|
2955
|
+
*/
|
2956
|
+
TokenTransferMessage.encode = function encode(message, writer) {
|
2957
|
+
if (!writer)
|
2958
|
+
writer = $Writer.create();
|
2959
|
+
if (message.to != null && Object.hasOwnProperty.call(message, "to"))
|
2960
|
+
writer.uint32(/* id 1, wireType 2 =*/10).string(message.to);
|
2961
|
+
if (message.amount != null && Object.hasOwnProperty.call(message, "amount"))
|
2962
|
+
writer.uint32(/* id 2, wireType 0 =*/16).uint64(message.amount);
|
2963
|
+
if (message["function"] != null && Object.hasOwnProperty.call(message, "function"))
|
2964
|
+
$root.TW.Aptos.Proto.StructTag.encode(message["function"], writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim();
|
2965
|
+
return writer;
|
2966
|
+
};
|
2967
|
+
|
2968
|
+
/**
|
2969
|
+
* Decodes a TokenTransferMessage message from the specified reader or buffer.
|
2970
|
+
* @function decode
|
2971
|
+
* @memberof TW.Aptos.Proto.TokenTransferMessage
|
2972
|
+
* @static
|
2973
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
2974
|
+
* @param {number} [length] Message length if known beforehand
|
2975
|
+
* @returns {TW.Aptos.Proto.TokenTransferMessage} TokenTransferMessage
|
2976
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
2977
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
2978
|
+
*/
|
2979
|
+
TokenTransferMessage.decode = function decode(reader, length) {
|
2980
|
+
if (!(reader instanceof $Reader))
|
2981
|
+
reader = $Reader.create(reader);
|
2982
|
+
var end = length === undefined ? reader.len : reader.pos + length, message = new $root.TW.Aptos.Proto.TokenTransferMessage();
|
2983
|
+
while (reader.pos < end) {
|
2984
|
+
var tag = reader.uint32();
|
2985
|
+
switch (tag >>> 3) {
|
2986
|
+
case 1:
|
2987
|
+
message.to = reader.string();
|
2988
|
+
break;
|
2989
|
+
case 2:
|
2990
|
+
message.amount = reader.uint64();
|
2991
|
+
break;
|
2992
|
+
case 3:
|
2993
|
+
message["function"] = $root.TW.Aptos.Proto.StructTag.decode(reader, reader.uint32());
|
2994
|
+
break;
|
2995
|
+
default:
|
2996
|
+
reader.skipType(tag & 7);
|
2997
|
+
break;
|
2998
|
+
}
|
2999
|
+
}
|
3000
|
+
return message;
|
3001
|
+
};
|
3002
|
+
|
3003
|
+
/**
|
3004
|
+
* Verifies a TokenTransferMessage message.
|
3005
|
+
* @function verify
|
3006
|
+
* @memberof TW.Aptos.Proto.TokenTransferMessage
|
3007
|
+
* @static
|
3008
|
+
* @param {Object.<string,*>} message Plain object to verify
|
3009
|
+
* @returns {string|null} `null` if valid, otherwise the reason why it is not
|
3010
|
+
*/
|
3011
|
+
TokenTransferMessage.verify = function verify(message) {
|
3012
|
+
if (typeof message !== "object" || message === null)
|
3013
|
+
return "object expected";
|
3014
|
+
if (message.to != null && message.hasOwnProperty("to"))
|
3015
|
+
if (!$util.isString(message.to))
|
3016
|
+
return "to: string expected";
|
3017
|
+
if (message.amount != null && message.hasOwnProperty("amount"))
|
3018
|
+
if (!$util.isInteger(message.amount) && !(message.amount && $util.isInteger(message.amount.low) && $util.isInteger(message.amount.high)))
|
3019
|
+
return "amount: integer|Long expected";
|
3020
|
+
if (message["function"] != null && message.hasOwnProperty("function")) {
|
3021
|
+
var error = $root.TW.Aptos.Proto.StructTag.verify(message["function"]);
|
3022
|
+
if (error)
|
3023
|
+
return "function." + error;
|
3024
|
+
}
|
3025
|
+
return null;
|
3026
|
+
};
|
3027
|
+
|
3028
|
+
/**
|
3029
|
+
* Creates a TokenTransferMessage message from a plain object. Also converts values to their respective internal types.
|
3030
|
+
* @function fromObject
|
3031
|
+
* @memberof TW.Aptos.Proto.TokenTransferMessage
|
3032
|
+
* @static
|
3033
|
+
* @param {Object.<string,*>} object Plain object
|
3034
|
+
* @returns {TW.Aptos.Proto.TokenTransferMessage} TokenTransferMessage
|
3035
|
+
*/
|
3036
|
+
TokenTransferMessage.fromObject = function fromObject(object) {
|
3037
|
+
if (object instanceof $root.TW.Aptos.Proto.TokenTransferMessage)
|
3038
|
+
return object;
|
3039
|
+
var message = new $root.TW.Aptos.Proto.TokenTransferMessage();
|
3040
|
+
if (object.to != null)
|
3041
|
+
message.to = String(object.to);
|
3042
|
+
if (object.amount != null)
|
3043
|
+
if ($util.Long)
|
3044
|
+
(message.amount = $util.Long.fromValue(object.amount)).unsigned = true;
|
3045
|
+
else if (typeof object.amount === "string")
|
3046
|
+
message.amount = parseInt(object.amount, 10);
|
3047
|
+
else if (typeof object.amount === "number")
|
3048
|
+
message.amount = object.amount;
|
3049
|
+
else if (typeof object.amount === "object")
|
3050
|
+
message.amount = new $util.LongBits(object.amount.low >>> 0, object.amount.high >>> 0).toNumber(true);
|
3051
|
+
if (object["function"] != null) {
|
3052
|
+
if (typeof object["function"] !== "object")
|
3053
|
+
throw TypeError(".TW.Aptos.Proto.TokenTransferMessage.function: object expected");
|
3054
|
+
message["function"] = $root.TW.Aptos.Proto.StructTag.fromObject(object["function"]);
|
3055
|
+
}
|
3056
|
+
return message;
|
3057
|
+
};
|
3058
|
+
|
3059
|
+
/**
|
3060
|
+
* Creates a plain object from a TokenTransferMessage message. Also converts values to other types if specified.
|
3061
|
+
* @function toObject
|
3062
|
+
* @memberof TW.Aptos.Proto.TokenTransferMessage
|
3063
|
+
* @static
|
3064
|
+
* @param {TW.Aptos.Proto.TokenTransferMessage} message TokenTransferMessage
|
3065
|
+
* @param {$protobuf.IConversionOptions} [options] Conversion options
|
3066
|
+
* @returns {Object.<string,*>} Plain object
|
3067
|
+
*/
|
3068
|
+
TokenTransferMessage.toObject = function toObject(message, options) {
|
3069
|
+
if (!options)
|
3070
|
+
options = {};
|
3071
|
+
var object = {};
|
3072
|
+
if (options.defaults) {
|
3073
|
+
object.to = "";
|
3074
|
+
if ($util.Long) {
|
3075
|
+
var long = new $util.Long(0, 0, true);
|
3076
|
+
object.amount = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long;
|
3077
|
+
} else
|
3078
|
+
object.amount = options.longs === String ? "0" : 0;
|
3079
|
+
object["function"] = null;
|
3080
|
+
}
|
3081
|
+
if (message.to != null && message.hasOwnProperty("to"))
|
3082
|
+
object.to = message.to;
|
3083
|
+
if (message.amount != null && message.hasOwnProperty("amount"))
|
3084
|
+
if (typeof message.amount === "number")
|
3085
|
+
object.amount = options.longs === String ? String(message.amount) : message.amount;
|
3086
|
+
else
|
3087
|
+
object.amount = options.longs === String ? $util.Long.prototype.toString.call(message.amount) : options.longs === Number ? new $util.LongBits(message.amount.low >>> 0, message.amount.high >>> 0).toNumber(true) : message.amount;
|
3088
|
+
if (message["function"] != null && message.hasOwnProperty("function"))
|
3089
|
+
object["function"] = $root.TW.Aptos.Proto.StructTag.toObject(message["function"], options);
|
3090
|
+
return object;
|
3091
|
+
};
|
3092
|
+
|
3093
|
+
/**
|
3094
|
+
* Converts this TokenTransferMessage to JSON.
|
3095
|
+
* @function toJSON
|
3096
|
+
* @memberof TW.Aptos.Proto.TokenTransferMessage
|
3097
|
+
* @instance
|
3098
|
+
* @returns {Object.<string,*>} JSON object
|
3099
|
+
*/
|
3100
|
+
TokenTransferMessage.prototype.toJSON = function toJSON() {
|
3101
|
+
return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
|
3102
|
+
};
|
3103
|
+
|
3104
|
+
return TokenTransferMessage;
|
3105
|
+
})();
|
3106
|
+
|
3107
|
+
Proto.CreateAccountMessage = (function() {
|
3108
|
+
|
3109
|
+
/**
|
3110
|
+
* Properties of a CreateAccountMessage.
|
3111
|
+
* @memberof TW.Aptos.Proto
|
3112
|
+
* @interface ICreateAccountMessage
|
3113
|
+
* @property {string|null} [authKey] CreateAccountMessage authKey
|
3114
|
+
*/
|
3115
|
+
|
3116
|
+
/**
|
3117
|
+
* Constructs a new CreateAccountMessage.
|
3118
|
+
* @memberof TW.Aptos.Proto
|
3119
|
+
* @classdesc Represents a CreateAccountMessage.
|
3120
|
+
* @implements ICreateAccountMessage
|
3121
|
+
* @constructor
|
3122
|
+
* @param {TW.Aptos.Proto.ICreateAccountMessage=} [properties] Properties to set
|
3123
|
+
*/
|
3124
|
+
function CreateAccountMessage(properties) {
|
3125
|
+
if (properties)
|
3126
|
+
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
|
3127
|
+
if (properties[keys[i]] != null)
|
3128
|
+
this[keys[i]] = properties[keys[i]];
|
3129
|
+
}
|
3130
|
+
|
3131
|
+
/**
|
3132
|
+
* CreateAccountMessage authKey.
|
3133
|
+
* @member {string} authKey
|
3134
|
+
* @memberof TW.Aptos.Proto.CreateAccountMessage
|
3135
|
+
* @instance
|
3136
|
+
*/
|
3137
|
+
CreateAccountMessage.prototype.authKey = "";
|
3138
|
+
|
3139
|
+
/**
|
3140
|
+
* Creates a new CreateAccountMessage instance using the specified properties.
|
3141
|
+
* @function create
|
3142
|
+
* @memberof TW.Aptos.Proto.CreateAccountMessage
|
3143
|
+
* @static
|
3144
|
+
* @param {TW.Aptos.Proto.ICreateAccountMessage=} [properties] Properties to set
|
3145
|
+
* @returns {TW.Aptos.Proto.CreateAccountMessage} CreateAccountMessage instance
|
3146
|
+
*/
|
3147
|
+
CreateAccountMessage.create = function create(properties) {
|
3148
|
+
return new CreateAccountMessage(properties);
|
3149
|
+
};
|
3150
|
+
|
3151
|
+
/**
|
3152
|
+
* Encodes the specified CreateAccountMessage message. Does not implicitly {@link TW.Aptos.Proto.CreateAccountMessage.verify|verify} messages.
|
3153
|
+
* @function encode
|
3154
|
+
* @memberof TW.Aptos.Proto.CreateAccountMessage
|
3155
|
+
* @static
|
3156
|
+
* @param {TW.Aptos.Proto.ICreateAccountMessage} message CreateAccountMessage message or plain object to encode
|
3157
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
3158
|
+
* @returns {$protobuf.Writer} Writer
|
3159
|
+
*/
|
3160
|
+
CreateAccountMessage.encode = function encode(message, writer) {
|
3161
|
+
if (!writer)
|
3162
|
+
writer = $Writer.create();
|
3163
|
+
if (message.authKey != null && Object.hasOwnProperty.call(message, "authKey"))
|
3164
|
+
writer.uint32(/* id 1, wireType 2 =*/10).string(message.authKey);
|
3165
|
+
return writer;
|
3166
|
+
};
|
3167
|
+
|
3168
|
+
/**
|
3169
|
+
* Decodes a CreateAccountMessage message from the specified reader or buffer.
|
3170
|
+
* @function decode
|
3171
|
+
* @memberof TW.Aptos.Proto.CreateAccountMessage
|
3172
|
+
* @static
|
3173
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
3174
|
+
* @param {number} [length] Message length if known beforehand
|
3175
|
+
* @returns {TW.Aptos.Proto.CreateAccountMessage} CreateAccountMessage
|
3176
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
3177
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
3178
|
+
*/
|
3179
|
+
CreateAccountMessage.decode = function decode(reader, length) {
|
3180
|
+
if (!(reader instanceof $Reader))
|
3181
|
+
reader = $Reader.create(reader);
|
3182
|
+
var end = length === undefined ? reader.len : reader.pos + length, message = new $root.TW.Aptos.Proto.CreateAccountMessage();
|
3183
|
+
while (reader.pos < end) {
|
3184
|
+
var tag = reader.uint32();
|
3185
|
+
switch (tag >>> 3) {
|
3186
|
+
case 1:
|
3187
|
+
message.authKey = reader.string();
|
3188
|
+
break;
|
3189
|
+
default:
|
3190
|
+
reader.skipType(tag & 7);
|
3191
|
+
break;
|
3192
|
+
}
|
3193
|
+
}
|
3194
|
+
return message;
|
3195
|
+
};
|
3196
|
+
|
3197
|
+
/**
|
3198
|
+
* Verifies a CreateAccountMessage message.
|
3199
|
+
* @function verify
|
3200
|
+
* @memberof TW.Aptos.Proto.CreateAccountMessage
|
3201
|
+
* @static
|
3202
|
+
* @param {Object.<string,*>} message Plain object to verify
|
3203
|
+
* @returns {string|null} `null` if valid, otherwise the reason why it is not
|
3204
|
+
*/
|
3205
|
+
CreateAccountMessage.verify = function verify(message) {
|
3206
|
+
if (typeof message !== "object" || message === null)
|
3207
|
+
return "object expected";
|
3208
|
+
if (message.authKey != null && message.hasOwnProperty("authKey"))
|
3209
|
+
if (!$util.isString(message.authKey))
|
3210
|
+
return "authKey: string expected";
|
3211
|
+
return null;
|
3212
|
+
};
|
3213
|
+
|
3214
|
+
/**
|
3215
|
+
* Creates a CreateAccountMessage message from a plain object. Also converts values to their respective internal types.
|
3216
|
+
* @function fromObject
|
3217
|
+
* @memberof TW.Aptos.Proto.CreateAccountMessage
|
3218
|
+
* @static
|
3219
|
+
* @param {Object.<string,*>} object Plain object
|
3220
|
+
* @returns {TW.Aptos.Proto.CreateAccountMessage} CreateAccountMessage
|
3221
|
+
*/
|
3222
|
+
CreateAccountMessage.fromObject = function fromObject(object) {
|
3223
|
+
if (object instanceof $root.TW.Aptos.Proto.CreateAccountMessage)
|
3224
|
+
return object;
|
3225
|
+
var message = new $root.TW.Aptos.Proto.CreateAccountMessage();
|
3226
|
+
if (object.authKey != null)
|
3227
|
+
message.authKey = String(object.authKey);
|
3228
|
+
return message;
|
3229
|
+
};
|
3230
|
+
|
3231
|
+
/**
|
3232
|
+
* Creates a plain object from a CreateAccountMessage message. Also converts values to other types if specified.
|
3233
|
+
* @function toObject
|
3234
|
+
* @memberof TW.Aptos.Proto.CreateAccountMessage
|
3235
|
+
* @static
|
3236
|
+
* @param {TW.Aptos.Proto.CreateAccountMessage} message CreateAccountMessage
|
3237
|
+
* @param {$protobuf.IConversionOptions} [options] Conversion options
|
3238
|
+
* @returns {Object.<string,*>} Plain object
|
3239
|
+
*/
|
3240
|
+
CreateAccountMessage.toObject = function toObject(message, options) {
|
3241
|
+
if (!options)
|
3242
|
+
options = {};
|
3243
|
+
var object = {};
|
3244
|
+
if (options.defaults)
|
3245
|
+
object.authKey = "";
|
3246
|
+
if (message.authKey != null && message.hasOwnProperty("authKey"))
|
3247
|
+
object.authKey = message.authKey;
|
3248
|
+
return object;
|
3249
|
+
};
|
3250
|
+
|
3251
|
+
/**
|
3252
|
+
* Converts this CreateAccountMessage to JSON.
|
3253
|
+
* @function toJSON
|
3254
|
+
* @memberof TW.Aptos.Proto.CreateAccountMessage
|
3255
|
+
* @instance
|
3256
|
+
* @returns {Object.<string,*>} JSON object
|
3257
|
+
*/
|
3258
|
+
CreateAccountMessage.prototype.toJSON = function toJSON() {
|
3259
|
+
return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
|
3260
|
+
};
|
3261
|
+
|
3262
|
+
return CreateAccountMessage;
|
3263
|
+
})();
|
3264
|
+
|
3265
|
+
Proto.SigningInput = (function() {
|
3266
|
+
|
3267
|
+
/**
|
3268
|
+
* Properties of a SigningInput.
|
3269
|
+
* @memberof TW.Aptos.Proto
|
3270
|
+
* @interface ISigningInput
|
3271
|
+
* @property {string|null} [sender] SigningInput sender
|
3272
|
+
* @property {Long|null} [sequenceNumber] SigningInput sequenceNumber
|
3273
|
+
* @property {TW.Aptos.Proto.ITransferMessage|null} [transfer] SigningInput transfer
|
3274
|
+
* @property {TW.Aptos.Proto.ITokenTransferMessage|null} [tokenTransfer] SigningInput tokenTransfer
|
3275
|
+
* @property {TW.Aptos.Proto.ICreateAccountMessage|null} [createAccount] SigningInput createAccount
|
3276
|
+
* @property {Long|null} [maxGasAmount] SigningInput maxGasAmount
|
3277
|
+
* @property {Long|null} [gasUnitPrice] SigningInput gasUnitPrice
|
3278
|
+
* @property {Long|null} [expirationTimestampSecs] SigningInput expirationTimestampSecs
|
3279
|
+
* @property {number|null} [chainId] SigningInput chainId
|
3280
|
+
* @property {Uint8Array|null} [privateKey] SigningInput privateKey
|
3281
|
+
* @property {string|null} [anyEncoded] SigningInput anyEncoded
|
3282
|
+
*/
|
3283
|
+
|
3284
|
+
/**
|
3285
|
+
* Constructs a new SigningInput.
|
3286
|
+
* @memberof TW.Aptos.Proto
|
3287
|
+
* @classdesc Represents a SigningInput.
|
3288
|
+
* @implements ISigningInput
|
3289
|
+
* @constructor
|
3290
|
+
* @param {TW.Aptos.Proto.ISigningInput=} [properties] Properties to set
|
3291
|
+
*/
|
3292
|
+
function SigningInput(properties) {
|
3293
|
+
if (properties)
|
3294
|
+
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
|
3295
|
+
if (properties[keys[i]] != null)
|
3296
|
+
this[keys[i]] = properties[keys[i]];
|
3297
|
+
}
|
3298
|
+
|
3299
|
+
/**
|
3300
|
+
* SigningInput sender.
|
3301
|
+
* @member {string} sender
|
3302
|
+
* @memberof TW.Aptos.Proto.SigningInput
|
3303
|
+
* @instance
|
3304
|
+
*/
|
3305
|
+
SigningInput.prototype.sender = "";
|
3306
|
+
|
3307
|
+
/**
|
3308
|
+
* SigningInput sequenceNumber.
|
3309
|
+
* @member {Long} sequenceNumber
|
3310
|
+
* @memberof TW.Aptos.Proto.SigningInput
|
3311
|
+
* @instance
|
3312
|
+
*/
|
3313
|
+
SigningInput.prototype.sequenceNumber = $util.Long ? $util.Long.fromBits(0,0,false) : 0;
|
3314
|
+
|
3315
|
+
/**
|
3316
|
+
* SigningInput transfer.
|
3317
|
+
* @member {TW.Aptos.Proto.ITransferMessage|null|undefined} transfer
|
3318
|
+
* @memberof TW.Aptos.Proto.SigningInput
|
3319
|
+
* @instance
|
3320
|
+
*/
|
3321
|
+
SigningInput.prototype.transfer = null;
|
3322
|
+
|
3323
|
+
/**
|
3324
|
+
* SigningInput tokenTransfer.
|
3325
|
+
* @member {TW.Aptos.Proto.ITokenTransferMessage|null|undefined} tokenTransfer
|
3326
|
+
* @memberof TW.Aptos.Proto.SigningInput
|
3327
|
+
* @instance
|
3328
|
+
*/
|
3329
|
+
SigningInput.prototype.tokenTransfer = null;
|
3330
|
+
|
3331
|
+
/**
|
3332
|
+
* SigningInput createAccount.
|
3333
|
+
* @member {TW.Aptos.Proto.ICreateAccountMessage|null|undefined} createAccount
|
3334
|
+
* @memberof TW.Aptos.Proto.SigningInput
|
3335
|
+
* @instance
|
3336
|
+
*/
|
3337
|
+
SigningInput.prototype.createAccount = null;
|
3338
|
+
|
3339
|
+
/**
|
3340
|
+
* SigningInput maxGasAmount.
|
3341
|
+
* @member {Long} maxGasAmount
|
3342
|
+
* @memberof TW.Aptos.Proto.SigningInput
|
3343
|
+
* @instance
|
3344
|
+
*/
|
3345
|
+
SigningInput.prototype.maxGasAmount = $util.Long ? $util.Long.fromBits(0,0,true) : 0;
|
3346
|
+
|
3347
|
+
/**
|
3348
|
+
* SigningInput gasUnitPrice.
|
3349
|
+
* @member {Long} gasUnitPrice
|
3350
|
+
* @memberof TW.Aptos.Proto.SigningInput
|
3351
|
+
* @instance
|
3352
|
+
*/
|
3353
|
+
SigningInput.prototype.gasUnitPrice = $util.Long ? $util.Long.fromBits(0,0,true) : 0;
|
3354
|
+
|
3355
|
+
/**
|
3356
|
+
* SigningInput expirationTimestampSecs.
|
3357
|
+
* @member {Long} expirationTimestampSecs
|
3358
|
+
* @memberof TW.Aptos.Proto.SigningInput
|
3359
|
+
* @instance
|
3360
|
+
*/
|
3361
|
+
SigningInput.prototype.expirationTimestampSecs = $util.Long ? $util.Long.fromBits(0,0,true) : 0;
|
3362
|
+
|
3363
|
+
/**
|
3364
|
+
* SigningInput chainId.
|
3365
|
+
* @member {number} chainId
|
3366
|
+
* @memberof TW.Aptos.Proto.SigningInput
|
3367
|
+
* @instance
|
3368
|
+
*/
|
3369
|
+
SigningInput.prototype.chainId = 0;
|
3370
|
+
|
3371
|
+
/**
|
3372
|
+
* SigningInput privateKey.
|
3373
|
+
* @member {Uint8Array} privateKey
|
3374
|
+
* @memberof TW.Aptos.Proto.SigningInput
|
3375
|
+
* @instance
|
3376
|
+
*/
|
3377
|
+
SigningInput.prototype.privateKey = $util.newBuffer([]);
|
3378
|
+
|
3379
|
+
/**
|
3380
|
+
* SigningInput anyEncoded.
|
3381
|
+
* @member {string} anyEncoded
|
3382
|
+
* @memberof TW.Aptos.Proto.SigningInput
|
3383
|
+
* @instance
|
3384
|
+
*/
|
3385
|
+
SigningInput.prototype.anyEncoded = "";
|
3386
|
+
|
3387
|
+
// OneOf field names bound to virtual getters and setters
|
3388
|
+
var $oneOfFields;
|
3389
|
+
|
3390
|
+
/**
|
3391
|
+
* SigningInput transactionPayload.
|
3392
|
+
* @member {"transfer"|"tokenTransfer"|"createAccount"|undefined} transactionPayload
|
3393
|
+
* @memberof TW.Aptos.Proto.SigningInput
|
3394
|
+
* @instance
|
3395
|
+
*/
|
3396
|
+
Object.defineProperty(SigningInput.prototype, "transactionPayload", {
|
3397
|
+
get: $util.oneOfGetter($oneOfFields = ["transfer", "tokenTransfer", "createAccount"]),
|
3398
|
+
set: $util.oneOfSetter($oneOfFields)
|
3399
|
+
});
|
3400
|
+
|
3401
|
+
/**
|
3402
|
+
* Creates a new SigningInput instance using the specified properties.
|
3403
|
+
* @function create
|
3404
|
+
* @memberof TW.Aptos.Proto.SigningInput
|
3405
|
+
* @static
|
3406
|
+
* @param {TW.Aptos.Proto.ISigningInput=} [properties] Properties to set
|
3407
|
+
* @returns {TW.Aptos.Proto.SigningInput} SigningInput instance
|
3408
|
+
*/
|
3409
|
+
SigningInput.create = function create(properties) {
|
3410
|
+
return new SigningInput(properties);
|
3411
|
+
};
|
3412
|
+
|
3413
|
+
/**
|
3414
|
+
* Encodes the specified SigningInput message. Does not implicitly {@link TW.Aptos.Proto.SigningInput.verify|verify} messages.
|
3415
|
+
* @function encode
|
3416
|
+
* @memberof TW.Aptos.Proto.SigningInput
|
3417
|
+
* @static
|
3418
|
+
* @param {TW.Aptos.Proto.ISigningInput} message SigningInput message or plain object to encode
|
3419
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
3420
|
+
* @returns {$protobuf.Writer} Writer
|
3421
|
+
*/
|
3422
|
+
SigningInput.encode = function encode(message, writer) {
|
3423
|
+
if (!writer)
|
3424
|
+
writer = $Writer.create();
|
3425
|
+
if (message.sender != null && Object.hasOwnProperty.call(message, "sender"))
|
3426
|
+
writer.uint32(/* id 1, wireType 2 =*/10).string(message.sender);
|
3427
|
+
if (message.sequenceNumber != null && Object.hasOwnProperty.call(message, "sequenceNumber"))
|
3428
|
+
writer.uint32(/* id 2, wireType 0 =*/16).int64(message.sequenceNumber);
|
3429
|
+
if (message.transfer != null && Object.hasOwnProperty.call(message, "transfer"))
|
3430
|
+
$root.TW.Aptos.Proto.TransferMessage.encode(message.transfer, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim();
|
3431
|
+
if (message.tokenTransfer != null && Object.hasOwnProperty.call(message, "tokenTransfer"))
|
3432
|
+
$root.TW.Aptos.Proto.TokenTransferMessage.encode(message.tokenTransfer, writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim();
|
3433
|
+
if (message.createAccount != null && Object.hasOwnProperty.call(message, "createAccount"))
|
3434
|
+
$root.TW.Aptos.Proto.CreateAccountMessage.encode(message.createAccount, writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim();
|
3435
|
+
if (message.maxGasAmount != null && Object.hasOwnProperty.call(message, "maxGasAmount"))
|
3436
|
+
writer.uint32(/* id 6, wireType 0 =*/48).uint64(message.maxGasAmount);
|
3437
|
+
if (message.gasUnitPrice != null && Object.hasOwnProperty.call(message, "gasUnitPrice"))
|
3438
|
+
writer.uint32(/* id 7, wireType 0 =*/56).uint64(message.gasUnitPrice);
|
3439
|
+
if (message.expirationTimestampSecs != null && Object.hasOwnProperty.call(message, "expirationTimestampSecs"))
|
3440
|
+
writer.uint32(/* id 8, wireType 0 =*/64).uint64(message.expirationTimestampSecs);
|
3441
|
+
if (message.chainId != null && Object.hasOwnProperty.call(message, "chainId"))
|
3442
|
+
writer.uint32(/* id 9, wireType 0 =*/72).uint32(message.chainId);
|
3443
|
+
if (message.privateKey != null && Object.hasOwnProperty.call(message, "privateKey"))
|
3444
|
+
writer.uint32(/* id 10, wireType 2 =*/82).bytes(message.privateKey);
|
3445
|
+
if (message.anyEncoded != null && Object.hasOwnProperty.call(message, "anyEncoded"))
|
3446
|
+
writer.uint32(/* id 11, wireType 2 =*/90).string(message.anyEncoded);
|
3447
|
+
return writer;
|
3448
|
+
};
|
3449
|
+
|
3450
|
+
/**
|
3451
|
+
* Decodes a SigningInput message from the specified reader or buffer.
|
3452
|
+
* @function decode
|
3453
|
+
* @memberof TW.Aptos.Proto.SigningInput
|
3454
|
+
* @static
|
3455
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
3456
|
+
* @param {number} [length] Message length if known beforehand
|
3457
|
+
* @returns {TW.Aptos.Proto.SigningInput} SigningInput
|
3458
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
3459
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
3460
|
+
*/
|
3461
|
+
SigningInput.decode = function decode(reader, length) {
|
3462
|
+
if (!(reader instanceof $Reader))
|
3463
|
+
reader = $Reader.create(reader);
|
3464
|
+
var end = length === undefined ? reader.len : reader.pos + length, message = new $root.TW.Aptos.Proto.SigningInput();
|
3465
|
+
while (reader.pos < end) {
|
3466
|
+
var tag = reader.uint32();
|
3467
|
+
switch (tag >>> 3) {
|
3468
|
+
case 1:
|
3469
|
+
message.sender = reader.string();
|
3470
|
+
break;
|
3471
|
+
case 2:
|
3472
|
+
message.sequenceNumber = reader.int64();
|
3473
|
+
break;
|
3474
|
+
case 3:
|
3475
|
+
message.transfer = $root.TW.Aptos.Proto.TransferMessage.decode(reader, reader.uint32());
|
3476
|
+
break;
|
3477
|
+
case 4:
|
3478
|
+
message.tokenTransfer = $root.TW.Aptos.Proto.TokenTransferMessage.decode(reader, reader.uint32());
|
3479
|
+
break;
|
3480
|
+
case 5:
|
3481
|
+
message.createAccount = $root.TW.Aptos.Proto.CreateAccountMessage.decode(reader, reader.uint32());
|
3482
|
+
break;
|
3483
|
+
case 6:
|
3484
|
+
message.maxGasAmount = reader.uint64();
|
3485
|
+
break;
|
3486
|
+
case 7:
|
3487
|
+
message.gasUnitPrice = reader.uint64();
|
3488
|
+
break;
|
3489
|
+
case 8:
|
3490
|
+
message.expirationTimestampSecs = reader.uint64();
|
3491
|
+
break;
|
3492
|
+
case 9:
|
3493
|
+
message.chainId = reader.uint32();
|
3494
|
+
break;
|
3495
|
+
case 10:
|
3496
|
+
message.privateKey = reader.bytes();
|
3497
|
+
break;
|
3498
|
+
case 11:
|
3499
|
+
message.anyEncoded = reader.string();
|
3500
|
+
break;
|
3501
|
+
default:
|
3502
|
+
reader.skipType(tag & 7);
|
3503
|
+
break;
|
3504
|
+
}
|
3505
|
+
}
|
3506
|
+
return message;
|
3507
|
+
};
|
3508
|
+
|
3509
|
+
/**
|
3510
|
+
* Verifies a SigningInput message.
|
3511
|
+
* @function verify
|
3512
|
+
* @memberof TW.Aptos.Proto.SigningInput
|
3513
|
+
* @static
|
3514
|
+
* @param {Object.<string,*>} message Plain object to verify
|
3515
|
+
* @returns {string|null} `null` if valid, otherwise the reason why it is not
|
3516
|
+
*/
|
3517
|
+
SigningInput.verify = function verify(message) {
|
3518
|
+
if (typeof message !== "object" || message === null)
|
3519
|
+
return "object expected";
|
3520
|
+
var properties = {};
|
3521
|
+
if (message.sender != null && message.hasOwnProperty("sender"))
|
3522
|
+
if (!$util.isString(message.sender))
|
3523
|
+
return "sender: string expected";
|
3524
|
+
if (message.sequenceNumber != null && message.hasOwnProperty("sequenceNumber"))
|
3525
|
+
if (!$util.isInteger(message.sequenceNumber) && !(message.sequenceNumber && $util.isInteger(message.sequenceNumber.low) && $util.isInteger(message.sequenceNumber.high)))
|
3526
|
+
return "sequenceNumber: integer|Long expected";
|
3527
|
+
if (message.transfer != null && message.hasOwnProperty("transfer")) {
|
3528
|
+
properties.transactionPayload = 1;
|
3529
|
+
{
|
3530
|
+
var error = $root.TW.Aptos.Proto.TransferMessage.verify(message.transfer);
|
3531
|
+
if (error)
|
3532
|
+
return "transfer." + error;
|
3533
|
+
}
|
3534
|
+
}
|
3535
|
+
if (message.tokenTransfer != null && message.hasOwnProperty("tokenTransfer")) {
|
3536
|
+
if (properties.transactionPayload === 1)
|
3537
|
+
return "transactionPayload: multiple values";
|
3538
|
+
properties.transactionPayload = 1;
|
3539
|
+
{
|
3540
|
+
var error = $root.TW.Aptos.Proto.TokenTransferMessage.verify(message.tokenTransfer);
|
3541
|
+
if (error)
|
3542
|
+
return "tokenTransfer." + error;
|
3543
|
+
}
|
3544
|
+
}
|
3545
|
+
if (message.createAccount != null && message.hasOwnProperty("createAccount")) {
|
3546
|
+
if (properties.transactionPayload === 1)
|
3547
|
+
return "transactionPayload: multiple values";
|
3548
|
+
properties.transactionPayload = 1;
|
3549
|
+
{
|
3550
|
+
var error = $root.TW.Aptos.Proto.CreateAccountMessage.verify(message.createAccount);
|
3551
|
+
if (error)
|
3552
|
+
return "createAccount." + error;
|
3553
|
+
}
|
3554
|
+
}
|
3555
|
+
if (message.maxGasAmount != null && message.hasOwnProperty("maxGasAmount"))
|
3556
|
+
if (!$util.isInteger(message.maxGasAmount) && !(message.maxGasAmount && $util.isInteger(message.maxGasAmount.low) && $util.isInteger(message.maxGasAmount.high)))
|
3557
|
+
return "maxGasAmount: integer|Long expected";
|
3558
|
+
if (message.gasUnitPrice != null && message.hasOwnProperty("gasUnitPrice"))
|
3559
|
+
if (!$util.isInteger(message.gasUnitPrice) && !(message.gasUnitPrice && $util.isInteger(message.gasUnitPrice.low) && $util.isInteger(message.gasUnitPrice.high)))
|
3560
|
+
return "gasUnitPrice: integer|Long expected";
|
3561
|
+
if (message.expirationTimestampSecs != null && message.hasOwnProperty("expirationTimestampSecs"))
|
3562
|
+
if (!$util.isInteger(message.expirationTimestampSecs) && !(message.expirationTimestampSecs && $util.isInteger(message.expirationTimestampSecs.low) && $util.isInteger(message.expirationTimestampSecs.high)))
|
3563
|
+
return "expirationTimestampSecs: integer|Long expected";
|
3564
|
+
if (message.chainId != null && message.hasOwnProperty("chainId"))
|
3565
|
+
if (!$util.isInteger(message.chainId))
|
3566
|
+
return "chainId: integer expected";
|
3567
|
+
if (message.privateKey != null && message.hasOwnProperty("privateKey"))
|
3568
|
+
if (!(message.privateKey && typeof message.privateKey.length === "number" || $util.isString(message.privateKey)))
|
3569
|
+
return "privateKey: buffer expected";
|
3570
|
+
if (message.anyEncoded != null && message.hasOwnProperty("anyEncoded"))
|
3571
|
+
if (!$util.isString(message.anyEncoded))
|
3572
|
+
return "anyEncoded: string expected";
|
3573
|
+
return null;
|
3574
|
+
};
|
3575
|
+
|
3576
|
+
/**
|
3577
|
+
* Creates a SigningInput message from a plain object. Also converts values to their respective internal types.
|
3578
|
+
* @function fromObject
|
3579
|
+
* @memberof TW.Aptos.Proto.SigningInput
|
3580
|
+
* @static
|
3581
|
+
* @param {Object.<string,*>} object Plain object
|
3582
|
+
* @returns {TW.Aptos.Proto.SigningInput} SigningInput
|
3583
|
+
*/
|
3584
|
+
SigningInput.fromObject = function fromObject(object) {
|
3585
|
+
if (object instanceof $root.TW.Aptos.Proto.SigningInput)
|
3586
|
+
return object;
|
3587
|
+
var message = new $root.TW.Aptos.Proto.SigningInput();
|
3588
|
+
if (object.sender != null)
|
3589
|
+
message.sender = String(object.sender);
|
3590
|
+
if (object.sequenceNumber != null)
|
3591
|
+
if ($util.Long)
|
3592
|
+
(message.sequenceNumber = $util.Long.fromValue(object.sequenceNumber)).unsigned = false;
|
3593
|
+
else if (typeof object.sequenceNumber === "string")
|
3594
|
+
message.sequenceNumber = parseInt(object.sequenceNumber, 10);
|
3595
|
+
else if (typeof object.sequenceNumber === "number")
|
3596
|
+
message.sequenceNumber = object.sequenceNumber;
|
3597
|
+
else if (typeof object.sequenceNumber === "object")
|
3598
|
+
message.sequenceNumber = new $util.LongBits(object.sequenceNumber.low >>> 0, object.sequenceNumber.high >>> 0).toNumber();
|
3599
|
+
if (object.transfer != null) {
|
3600
|
+
if (typeof object.transfer !== "object")
|
3601
|
+
throw TypeError(".TW.Aptos.Proto.SigningInput.transfer: object expected");
|
3602
|
+
message.transfer = $root.TW.Aptos.Proto.TransferMessage.fromObject(object.transfer);
|
3603
|
+
}
|
3604
|
+
if (object.tokenTransfer != null) {
|
3605
|
+
if (typeof object.tokenTransfer !== "object")
|
3606
|
+
throw TypeError(".TW.Aptos.Proto.SigningInput.tokenTransfer: object expected");
|
3607
|
+
message.tokenTransfer = $root.TW.Aptos.Proto.TokenTransferMessage.fromObject(object.tokenTransfer);
|
3608
|
+
}
|
3609
|
+
if (object.createAccount != null) {
|
3610
|
+
if (typeof object.createAccount !== "object")
|
3611
|
+
throw TypeError(".TW.Aptos.Proto.SigningInput.createAccount: object expected");
|
3612
|
+
message.createAccount = $root.TW.Aptos.Proto.CreateAccountMessage.fromObject(object.createAccount);
|
3613
|
+
}
|
3614
|
+
if (object.maxGasAmount != null)
|
3615
|
+
if ($util.Long)
|
3616
|
+
(message.maxGasAmount = $util.Long.fromValue(object.maxGasAmount)).unsigned = true;
|
3617
|
+
else if (typeof object.maxGasAmount === "string")
|
3618
|
+
message.maxGasAmount = parseInt(object.maxGasAmount, 10);
|
3619
|
+
else if (typeof object.maxGasAmount === "number")
|
3620
|
+
message.maxGasAmount = object.maxGasAmount;
|
3621
|
+
else if (typeof object.maxGasAmount === "object")
|
3622
|
+
message.maxGasAmount = new $util.LongBits(object.maxGasAmount.low >>> 0, object.maxGasAmount.high >>> 0).toNumber(true);
|
3623
|
+
if (object.gasUnitPrice != null)
|
3624
|
+
if ($util.Long)
|
3625
|
+
(message.gasUnitPrice = $util.Long.fromValue(object.gasUnitPrice)).unsigned = true;
|
3626
|
+
else if (typeof object.gasUnitPrice === "string")
|
3627
|
+
message.gasUnitPrice = parseInt(object.gasUnitPrice, 10);
|
3628
|
+
else if (typeof object.gasUnitPrice === "number")
|
3629
|
+
message.gasUnitPrice = object.gasUnitPrice;
|
3630
|
+
else if (typeof object.gasUnitPrice === "object")
|
3631
|
+
message.gasUnitPrice = new $util.LongBits(object.gasUnitPrice.low >>> 0, object.gasUnitPrice.high >>> 0).toNumber(true);
|
3632
|
+
if (object.expirationTimestampSecs != null)
|
3633
|
+
if ($util.Long)
|
3634
|
+
(message.expirationTimestampSecs = $util.Long.fromValue(object.expirationTimestampSecs)).unsigned = true;
|
3635
|
+
else if (typeof object.expirationTimestampSecs === "string")
|
3636
|
+
message.expirationTimestampSecs = parseInt(object.expirationTimestampSecs, 10);
|
3637
|
+
else if (typeof object.expirationTimestampSecs === "number")
|
3638
|
+
message.expirationTimestampSecs = object.expirationTimestampSecs;
|
3639
|
+
else if (typeof object.expirationTimestampSecs === "object")
|
3640
|
+
message.expirationTimestampSecs = new $util.LongBits(object.expirationTimestampSecs.low >>> 0, object.expirationTimestampSecs.high >>> 0).toNumber(true);
|
3641
|
+
if (object.chainId != null)
|
3642
|
+
message.chainId = object.chainId >>> 0;
|
3643
|
+
if (object.privateKey != null)
|
3644
|
+
if (typeof object.privateKey === "string")
|
3645
|
+
$util.base64.decode(object.privateKey, message.privateKey = $util.newBuffer($util.base64.length(object.privateKey)), 0);
|
3646
|
+
else if (object.privateKey.length)
|
3647
|
+
message.privateKey = object.privateKey;
|
3648
|
+
if (object.anyEncoded != null)
|
3649
|
+
message.anyEncoded = String(object.anyEncoded);
|
3650
|
+
return message;
|
3651
|
+
};
|
3652
|
+
|
3653
|
+
/**
|
3654
|
+
* Creates a plain object from a SigningInput message. Also converts values to other types if specified.
|
3655
|
+
* @function toObject
|
3656
|
+
* @memberof TW.Aptos.Proto.SigningInput
|
3657
|
+
* @static
|
3658
|
+
* @param {TW.Aptos.Proto.SigningInput} message SigningInput
|
3659
|
+
* @param {$protobuf.IConversionOptions} [options] Conversion options
|
3660
|
+
* @returns {Object.<string,*>} Plain object
|
3661
|
+
*/
|
3662
|
+
SigningInput.toObject = function toObject(message, options) {
|
3663
|
+
if (!options)
|
3664
|
+
options = {};
|
3665
|
+
var object = {};
|
3666
|
+
if (options.defaults) {
|
3667
|
+
object.sender = "";
|
3668
|
+
if ($util.Long) {
|
3669
|
+
var long = new $util.Long(0, 0, false);
|
3670
|
+
object.sequenceNumber = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long;
|
3671
|
+
} else
|
3672
|
+
object.sequenceNumber = options.longs === String ? "0" : 0;
|
3673
|
+
if ($util.Long) {
|
3674
|
+
var long = new $util.Long(0, 0, true);
|
3675
|
+
object.maxGasAmount = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long;
|
3676
|
+
} else
|
3677
|
+
object.maxGasAmount = options.longs === String ? "0" : 0;
|
3678
|
+
if ($util.Long) {
|
3679
|
+
var long = new $util.Long(0, 0, true);
|
3680
|
+
object.gasUnitPrice = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long;
|
3681
|
+
} else
|
3682
|
+
object.gasUnitPrice = options.longs === String ? "0" : 0;
|
3683
|
+
if ($util.Long) {
|
3684
|
+
var long = new $util.Long(0, 0, true);
|
3685
|
+
object.expirationTimestampSecs = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long;
|
3686
|
+
} else
|
3687
|
+
object.expirationTimestampSecs = options.longs === String ? "0" : 0;
|
3688
|
+
object.chainId = 0;
|
3689
|
+
if (options.bytes === String)
|
3690
|
+
object.privateKey = "";
|
3691
|
+
else {
|
3692
|
+
object.privateKey = [];
|
3693
|
+
if (options.bytes !== Array)
|
3694
|
+
object.privateKey = $util.newBuffer(object.privateKey);
|
3695
|
+
}
|
3696
|
+
object.anyEncoded = "";
|
3697
|
+
}
|
3698
|
+
if (message.sender != null && message.hasOwnProperty("sender"))
|
3699
|
+
object.sender = message.sender;
|
3700
|
+
if (message.sequenceNumber != null && message.hasOwnProperty("sequenceNumber"))
|
3701
|
+
if (typeof message.sequenceNumber === "number")
|
3702
|
+
object.sequenceNumber = options.longs === String ? String(message.sequenceNumber) : message.sequenceNumber;
|
3703
|
+
else
|
3704
|
+
object.sequenceNumber = options.longs === String ? $util.Long.prototype.toString.call(message.sequenceNumber) : options.longs === Number ? new $util.LongBits(message.sequenceNumber.low >>> 0, message.sequenceNumber.high >>> 0).toNumber() : message.sequenceNumber;
|
3705
|
+
if (message.transfer != null && message.hasOwnProperty("transfer")) {
|
3706
|
+
object.transfer = $root.TW.Aptos.Proto.TransferMessage.toObject(message.transfer, options);
|
3707
|
+
if (options.oneofs)
|
3708
|
+
object.transactionPayload = "transfer";
|
3709
|
+
}
|
3710
|
+
if (message.tokenTransfer != null && message.hasOwnProperty("tokenTransfer")) {
|
3711
|
+
object.tokenTransfer = $root.TW.Aptos.Proto.TokenTransferMessage.toObject(message.tokenTransfer, options);
|
3712
|
+
if (options.oneofs)
|
3713
|
+
object.transactionPayload = "tokenTransfer";
|
3714
|
+
}
|
3715
|
+
if (message.createAccount != null && message.hasOwnProperty("createAccount")) {
|
3716
|
+
object.createAccount = $root.TW.Aptos.Proto.CreateAccountMessage.toObject(message.createAccount, options);
|
3717
|
+
if (options.oneofs)
|
3718
|
+
object.transactionPayload = "createAccount";
|
3719
|
+
}
|
3720
|
+
if (message.maxGasAmount != null && message.hasOwnProperty("maxGasAmount"))
|
3721
|
+
if (typeof message.maxGasAmount === "number")
|
3722
|
+
object.maxGasAmount = options.longs === String ? String(message.maxGasAmount) : message.maxGasAmount;
|
3723
|
+
else
|
3724
|
+
object.maxGasAmount = options.longs === String ? $util.Long.prototype.toString.call(message.maxGasAmount) : options.longs === Number ? new $util.LongBits(message.maxGasAmount.low >>> 0, message.maxGasAmount.high >>> 0).toNumber(true) : message.maxGasAmount;
|
3725
|
+
if (message.gasUnitPrice != null && message.hasOwnProperty("gasUnitPrice"))
|
3726
|
+
if (typeof message.gasUnitPrice === "number")
|
3727
|
+
object.gasUnitPrice = options.longs === String ? String(message.gasUnitPrice) : message.gasUnitPrice;
|
3728
|
+
else
|
3729
|
+
object.gasUnitPrice = options.longs === String ? $util.Long.prototype.toString.call(message.gasUnitPrice) : options.longs === Number ? new $util.LongBits(message.gasUnitPrice.low >>> 0, message.gasUnitPrice.high >>> 0).toNumber(true) : message.gasUnitPrice;
|
3730
|
+
if (message.expirationTimestampSecs != null && message.hasOwnProperty("expirationTimestampSecs"))
|
3731
|
+
if (typeof message.expirationTimestampSecs === "number")
|
3732
|
+
object.expirationTimestampSecs = options.longs === String ? String(message.expirationTimestampSecs) : message.expirationTimestampSecs;
|
3733
|
+
else
|
3734
|
+
object.expirationTimestampSecs = options.longs === String ? $util.Long.prototype.toString.call(message.expirationTimestampSecs) : options.longs === Number ? new $util.LongBits(message.expirationTimestampSecs.low >>> 0, message.expirationTimestampSecs.high >>> 0).toNumber(true) : message.expirationTimestampSecs;
|
3735
|
+
if (message.chainId != null && message.hasOwnProperty("chainId"))
|
3736
|
+
object.chainId = message.chainId;
|
3737
|
+
if (message.privateKey != null && message.hasOwnProperty("privateKey"))
|
3738
|
+
object.privateKey = options.bytes === String ? $util.base64.encode(message.privateKey, 0, message.privateKey.length) : options.bytes === Array ? Array.prototype.slice.call(message.privateKey) : message.privateKey;
|
3739
|
+
if (message.anyEncoded != null && message.hasOwnProperty("anyEncoded"))
|
3740
|
+
object.anyEncoded = message.anyEncoded;
|
3741
|
+
return object;
|
3742
|
+
};
|
3743
|
+
|
3744
|
+
/**
|
3745
|
+
* Converts this SigningInput to JSON.
|
3746
|
+
* @function toJSON
|
3747
|
+
* @memberof TW.Aptos.Proto.SigningInput
|
3748
|
+
* @instance
|
3749
|
+
* @returns {Object.<string,*>} JSON object
|
3750
|
+
*/
|
3751
|
+
SigningInput.prototype.toJSON = function toJSON() {
|
3752
|
+
return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
|
3753
|
+
};
|
3754
|
+
|
3755
|
+
return SigningInput;
|
3756
|
+
})();
|
3757
|
+
|
3758
|
+
Proto.TransactionAuthenticator = (function() {
|
3759
|
+
|
3760
|
+
/**
|
3761
|
+
* Properties of a TransactionAuthenticator.
|
3762
|
+
* @memberof TW.Aptos.Proto
|
3763
|
+
* @interface ITransactionAuthenticator
|
3764
|
+
* @property {Uint8Array|null} [signature] TransactionAuthenticator signature
|
3765
|
+
* @property {Uint8Array|null} [publicKey] TransactionAuthenticator publicKey
|
3766
|
+
*/
|
3767
|
+
|
3768
|
+
/**
|
3769
|
+
* Constructs a new TransactionAuthenticator.
|
3770
|
+
* @memberof TW.Aptos.Proto
|
3771
|
+
* @classdesc Represents a TransactionAuthenticator.
|
3772
|
+
* @implements ITransactionAuthenticator
|
3773
|
+
* @constructor
|
3774
|
+
* @param {TW.Aptos.Proto.ITransactionAuthenticator=} [properties] Properties to set
|
3775
|
+
*/
|
3776
|
+
function TransactionAuthenticator(properties) {
|
3777
|
+
if (properties)
|
3778
|
+
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
|
3779
|
+
if (properties[keys[i]] != null)
|
3780
|
+
this[keys[i]] = properties[keys[i]];
|
3781
|
+
}
|
3782
|
+
|
3783
|
+
/**
|
3784
|
+
* TransactionAuthenticator signature.
|
3785
|
+
* @member {Uint8Array} signature
|
3786
|
+
* @memberof TW.Aptos.Proto.TransactionAuthenticator
|
3787
|
+
* @instance
|
3788
|
+
*/
|
3789
|
+
TransactionAuthenticator.prototype.signature = $util.newBuffer([]);
|
3790
|
+
|
3791
|
+
/**
|
3792
|
+
* TransactionAuthenticator publicKey.
|
3793
|
+
* @member {Uint8Array} publicKey
|
3794
|
+
* @memberof TW.Aptos.Proto.TransactionAuthenticator
|
3795
|
+
* @instance
|
3796
|
+
*/
|
3797
|
+
TransactionAuthenticator.prototype.publicKey = $util.newBuffer([]);
|
3798
|
+
|
3799
|
+
/**
|
3800
|
+
* Creates a new TransactionAuthenticator instance using the specified properties.
|
3801
|
+
* @function create
|
3802
|
+
* @memberof TW.Aptos.Proto.TransactionAuthenticator
|
3803
|
+
* @static
|
3804
|
+
* @param {TW.Aptos.Proto.ITransactionAuthenticator=} [properties] Properties to set
|
3805
|
+
* @returns {TW.Aptos.Proto.TransactionAuthenticator} TransactionAuthenticator instance
|
3806
|
+
*/
|
3807
|
+
TransactionAuthenticator.create = function create(properties) {
|
3808
|
+
return new TransactionAuthenticator(properties);
|
3809
|
+
};
|
3810
|
+
|
3811
|
+
/**
|
3812
|
+
* Encodes the specified TransactionAuthenticator message. Does not implicitly {@link TW.Aptos.Proto.TransactionAuthenticator.verify|verify} messages.
|
3813
|
+
* @function encode
|
3814
|
+
* @memberof TW.Aptos.Proto.TransactionAuthenticator
|
3815
|
+
* @static
|
3816
|
+
* @param {TW.Aptos.Proto.ITransactionAuthenticator} message TransactionAuthenticator message or plain object to encode
|
3817
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
3818
|
+
* @returns {$protobuf.Writer} Writer
|
3819
|
+
*/
|
3820
|
+
TransactionAuthenticator.encode = function encode(message, writer) {
|
3821
|
+
if (!writer)
|
3822
|
+
writer = $Writer.create();
|
3823
|
+
if (message.signature != null && Object.hasOwnProperty.call(message, "signature"))
|
3824
|
+
writer.uint32(/* id 1, wireType 2 =*/10).bytes(message.signature);
|
3825
|
+
if (message.publicKey != null && Object.hasOwnProperty.call(message, "publicKey"))
|
3826
|
+
writer.uint32(/* id 2, wireType 2 =*/18).bytes(message.publicKey);
|
3827
|
+
return writer;
|
3828
|
+
};
|
3829
|
+
|
3830
|
+
/**
|
3831
|
+
* Decodes a TransactionAuthenticator message from the specified reader or buffer.
|
3832
|
+
* @function decode
|
3833
|
+
* @memberof TW.Aptos.Proto.TransactionAuthenticator
|
3834
|
+
* @static
|
3835
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
3836
|
+
* @param {number} [length] Message length if known beforehand
|
3837
|
+
* @returns {TW.Aptos.Proto.TransactionAuthenticator} TransactionAuthenticator
|
3838
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
3839
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
3840
|
+
*/
|
3841
|
+
TransactionAuthenticator.decode = function decode(reader, length) {
|
3842
|
+
if (!(reader instanceof $Reader))
|
3843
|
+
reader = $Reader.create(reader);
|
3844
|
+
var end = length === undefined ? reader.len : reader.pos + length, message = new $root.TW.Aptos.Proto.TransactionAuthenticator();
|
3845
|
+
while (reader.pos < end) {
|
3846
|
+
var tag = reader.uint32();
|
3847
|
+
switch (tag >>> 3) {
|
3848
|
+
case 1:
|
3849
|
+
message.signature = reader.bytes();
|
3850
|
+
break;
|
3851
|
+
case 2:
|
3852
|
+
message.publicKey = reader.bytes();
|
3853
|
+
break;
|
3854
|
+
default:
|
3855
|
+
reader.skipType(tag & 7);
|
3856
|
+
break;
|
3857
|
+
}
|
3858
|
+
}
|
3859
|
+
return message;
|
3860
|
+
};
|
3861
|
+
|
3862
|
+
/**
|
3863
|
+
* Verifies a TransactionAuthenticator message.
|
3864
|
+
* @function verify
|
3865
|
+
* @memberof TW.Aptos.Proto.TransactionAuthenticator
|
3866
|
+
* @static
|
3867
|
+
* @param {Object.<string,*>} message Plain object to verify
|
3868
|
+
* @returns {string|null} `null` if valid, otherwise the reason why it is not
|
3869
|
+
*/
|
3870
|
+
TransactionAuthenticator.verify = function verify(message) {
|
3871
|
+
if (typeof message !== "object" || message === null)
|
3872
|
+
return "object expected";
|
3873
|
+
if (message.signature != null && message.hasOwnProperty("signature"))
|
3874
|
+
if (!(message.signature && typeof message.signature.length === "number" || $util.isString(message.signature)))
|
3875
|
+
return "signature: buffer expected";
|
3876
|
+
if (message.publicKey != null && message.hasOwnProperty("publicKey"))
|
3877
|
+
if (!(message.publicKey && typeof message.publicKey.length === "number" || $util.isString(message.publicKey)))
|
3878
|
+
return "publicKey: buffer expected";
|
3879
|
+
return null;
|
3880
|
+
};
|
3881
|
+
|
3882
|
+
/**
|
3883
|
+
* Creates a TransactionAuthenticator message from a plain object. Also converts values to their respective internal types.
|
3884
|
+
* @function fromObject
|
3885
|
+
* @memberof TW.Aptos.Proto.TransactionAuthenticator
|
3886
|
+
* @static
|
3887
|
+
* @param {Object.<string,*>} object Plain object
|
3888
|
+
* @returns {TW.Aptos.Proto.TransactionAuthenticator} TransactionAuthenticator
|
3889
|
+
*/
|
3890
|
+
TransactionAuthenticator.fromObject = function fromObject(object) {
|
3891
|
+
if (object instanceof $root.TW.Aptos.Proto.TransactionAuthenticator)
|
3892
|
+
return object;
|
3893
|
+
var message = new $root.TW.Aptos.Proto.TransactionAuthenticator();
|
3894
|
+
if (object.signature != null)
|
3895
|
+
if (typeof object.signature === "string")
|
3896
|
+
$util.base64.decode(object.signature, message.signature = $util.newBuffer($util.base64.length(object.signature)), 0);
|
3897
|
+
else if (object.signature.length)
|
3898
|
+
message.signature = object.signature;
|
3899
|
+
if (object.publicKey != null)
|
3900
|
+
if (typeof object.publicKey === "string")
|
3901
|
+
$util.base64.decode(object.publicKey, message.publicKey = $util.newBuffer($util.base64.length(object.publicKey)), 0);
|
3902
|
+
else if (object.publicKey.length)
|
3903
|
+
message.publicKey = object.publicKey;
|
3904
|
+
return message;
|
3905
|
+
};
|
3906
|
+
|
3907
|
+
/**
|
3908
|
+
* Creates a plain object from a TransactionAuthenticator message. Also converts values to other types if specified.
|
3909
|
+
* @function toObject
|
3910
|
+
* @memberof TW.Aptos.Proto.TransactionAuthenticator
|
3911
|
+
* @static
|
3912
|
+
* @param {TW.Aptos.Proto.TransactionAuthenticator} message TransactionAuthenticator
|
3913
|
+
* @param {$protobuf.IConversionOptions} [options] Conversion options
|
3914
|
+
* @returns {Object.<string,*>} Plain object
|
3915
|
+
*/
|
3916
|
+
TransactionAuthenticator.toObject = function toObject(message, options) {
|
3917
|
+
if (!options)
|
3918
|
+
options = {};
|
3919
|
+
var object = {};
|
3920
|
+
if (options.defaults) {
|
3921
|
+
if (options.bytes === String)
|
3922
|
+
object.signature = "";
|
3923
|
+
else {
|
3924
|
+
object.signature = [];
|
3925
|
+
if (options.bytes !== Array)
|
3926
|
+
object.signature = $util.newBuffer(object.signature);
|
3927
|
+
}
|
3928
|
+
if (options.bytes === String)
|
3929
|
+
object.publicKey = "";
|
3930
|
+
else {
|
3931
|
+
object.publicKey = [];
|
3932
|
+
if (options.bytes !== Array)
|
3933
|
+
object.publicKey = $util.newBuffer(object.publicKey);
|
3934
|
+
}
|
3935
|
+
}
|
3936
|
+
if (message.signature != null && message.hasOwnProperty("signature"))
|
3937
|
+
object.signature = options.bytes === String ? $util.base64.encode(message.signature, 0, message.signature.length) : options.bytes === Array ? Array.prototype.slice.call(message.signature) : message.signature;
|
3938
|
+
if (message.publicKey != null && message.hasOwnProperty("publicKey"))
|
3939
|
+
object.publicKey = options.bytes === String ? $util.base64.encode(message.publicKey, 0, message.publicKey.length) : options.bytes === Array ? Array.prototype.slice.call(message.publicKey) : message.publicKey;
|
3940
|
+
return object;
|
3941
|
+
};
|
3942
|
+
|
3943
|
+
/**
|
3944
|
+
* Converts this TransactionAuthenticator to JSON.
|
3945
|
+
* @function toJSON
|
3946
|
+
* @memberof TW.Aptos.Proto.TransactionAuthenticator
|
3947
|
+
* @instance
|
3948
|
+
* @returns {Object.<string,*>} JSON object
|
3949
|
+
*/
|
3950
|
+
TransactionAuthenticator.prototype.toJSON = function toJSON() {
|
3951
|
+
return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
|
3952
|
+
};
|
3953
|
+
|
3954
|
+
return TransactionAuthenticator;
|
3955
|
+
})();
|
3956
|
+
|
3957
|
+
Proto.SigningOutput = (function() {
|
3958
|
+
|
3959
|
+
/**
|
3960
|
+
* Properties of a SigningOutput.
|
3961
|
+
* @memberof TW.Aptos.Proto
|
3962
|
+
* @interface ISigningOutput
|
3963
|
+
* @property {Uint8Array|null} [rawTxn] The raw transaction (bytes)
|
3964
|
+
* @property {TW.Aptos.Proto.ITransactionAuthenticator|null} [authenticator] Public key and signature to authenticate
|
3965
|
+
* @property {Uint8Array|null} [encoded] Signed and encoded transaction bytes.
|
3966
|
+
* @property {string|null} [json] SigningOutput json
|
3967
|
+
*/
|
3968
|
+
|
3969
|
+
/**
|
3970
|
+
* Constructs a new SigningOutput.
|
3971
|
+
* @memberof TW.Aptos.Proto
|
3972
|
+
* @classdesc Represents a SigningOutput.
|
3973
|
+
* @implements ISigningOutput
|
3974
|
+
* @constructor
|
3975
|
+
* @param {TW.Aptos.Proto.ISigningOutput=} [properties] Properties to set
|
3976
|
+
*/
|
3977
|
+
function SigningOutput(properties) {
|
3978
|
+
if (properties)
|
3979
|
+
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
|
3980
|
+
if (properties[keys[i]] != null)
|
3981
|
+
this[keys[i]] = properties[keys[i]];
|
3982
|
+
}
|
3983
|
+
|
3984
|
+
/**
|
3985
|
+
* The raw transaction (bytes)
|
3986
|
+
* @member {Uint8Array} rawTxn
|
3987
|
+
* @memberof TW.Aptos.Proto.SigningOutput
|
3988
|
+
* @instance
|
3989
|
+
*/
|
3990
|
+
SigningOutput.prototype.rawTxn = $util.newBuffer([]);
|
3991
|
+
|
3992
|
+
/**
|
3993
|
+
* Public key and signature to authenticate
|
3994
|
+
* @member {TW.Aptos.Proto.ITransactionAuthenticator|null|undefined} authenticator
|
3995
|
+
* @memberof TW.Aptos.Proto.SigningOutput
|
3996
|
+
* @instance
|
3997
|
+
*/
|
3998
|
+
SigningOutput.prototype.authenticator = null;
|
3999
|
+
|
4000
|
+
/**
|
4001
|
+
* Signed and encoded transaction bytes.
|
4002
|
+
* @member {Uint8Array} encoded
|
4003
|
+
* @memberof TW.Aptos.Proto.SigningOutput
|
4004
|
+
* @instance
|
4005
|
+
*/
|
4006
|
+
SigningOutput.prototype.encoded = $util.newBuffer([]);
|
4007
|
+
|
4008
|
+
/**
|
4009
|
+
* SigningOutput json.
|
4010
|
+
* @member {string} json
|
4011
|
+
* @memberof TW.Aptos.Proto.SigningOutput
|
4012
|
+
* @instance
|
4013
|
+
*/
|
4014
|
+
SigningOutput.prototype.json = "";
|
4015
|
+
|
4016
|
+
/**
|
4017
|
+
* Creates a new SigningOutput instance using the specified properties.
|
4018
|
+
* @function create
|
4019
|
+
* @memberof TW.Aptos.Proto.SigningOutput
|
4020
|
+
* @static
|
4021
|
+
* @param {TW.Aptos.Proto.ISigningOutput=} [properties] Properties to set
|
4022
|
+
* @returns {TW.Aptos.Proto.SigningOutput} SigningOutput instance
|
4023
|
+
*/
|
4024
|
+
SigningOutput.create = function create(properties) {
|
4025
|
+
return new SigningOutput(properties);
|
4026
|
+
};
|
4027
|
+
|
4028
|
+
/**
|
4029
|
+
* Encodes the specified SigningOutput message. Does not implicitly {@link TW.Aptos.Proto.SigningOutput.verify|verify} messages.
|
4030
|
+
* @function encode
|
4031
|
+
* @memberof TW.Aptos.Proto.SigningOutput
|
4032
|
+
* @static
|
4033
|
+
* @param {TW.Aptos.Proto.ISigningOutput} message SigningOutput message or plain object to encode
|
4034
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
4035
|
+
* @returns {$protobuf.Writer} Writer
|
4036
|
+
*/
|
4037
|
+
SigningOutput.encode = function encode(message, writer) {
|
4038
|
+
if (!writer)
|
4039
|
+
writer = $Writer.create();
|
4040
|
+
if (message.rawTxn != null && Object.hasOwnProperty.call(message, "rawTxn"))
|
4041
|
+
writer.uint32(/* id 1, wireType 2 =*/10).bytes(message.rawTxn);
|
4042
|
+
if (message.authenticator != null && Object.hasOwnProperty.call(message, "authenticator"))
|
4043
|
+
$root.TW.Aptos.Proto.TransactionAuthenticator.encode(message.authenticator, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim();
|
4044
|
+
if (message.encoded != null && Object.hasOwnProperty.call(message, "encoded"))
|
4045
|
+
writer.uint32(/* id 3, wireType 2 =*/26).bytes(message.encoded);
|
4046
|
+
if (message.json != null && Object.hasOwnProperty.call(message, "json"))
|
4047
|
+
writer.uint32(/* id 4, wireType 2 =*/34).string(message.json);
|
4048
|
+
return writer;
|
4049
|
+
};
|
4050
|
+
|
4051
|
+
/**
|
4052
|
+
* Decodes a SigningOutput message from the specified reader or buffer.
|
4053
|
+
* @function decode
|
4054
|
+
* @memberof TW.Aptos.Proto.SigningOutput
|
4055
|
+
* @static
|
4056
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
4057
|
+
* @param {number} [length] Message length if known beforehand
|
4058
|
+
* @returns {TW.Aptos.Proto.SigningOutput} SigningOutput
|
4059
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
4060
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
4061
|
+
*/
|
4062
|
+
SigningOutput.decode = function decode(reader, length) {
|
4063
|
+
if (!(reader instanceof $Reader))
|
4064
|
+
reader = $Reader.create(reader);
|
4065
|
+
var end = length === undefined ? reader.len : reader.pos + length, message = new $root.TW.Aptos.Proto.SigningOutput();
|
4066
|
+
while (reader.pos < end) {
|
4067
|
+
var tag = reader.uint32();
|
4068
|
+
switch (tag >>> 3) {
|
4069
|
+
case 1:
|
4070
|
+
message.rawTxn = reader.bytes();
|
4071
|
+
break;
|
4072
|
+
case 2:
|
4073
|
+
message.authenticator = $root.TW.Aptos.Proto.TransactionAuthenticator.decode(reader, reader.uint32());
|
4074
|
+
break;
|
4075
|
+
case 3:
|
4076
|
+
message.encoded = reader.bytes();
|
4077
|
+
break;
|
4078
|
+
case 4:
|
4079
|
+
message.json = reader.string();
|
4080
|
+
break;
|
4081
|
+
default:
|
4082
|
+
reader.skipType(tag & 7);
|
4083
|
+
break;
|
4084
|
+
}
|
4085
|
+
}
|
4086
|
+
return message;
|
4087
|
+
};
|
4088
|
+
|
4089
|
+
/**
|
4090
|
+
* Verifies a SigningOutput message.
|
4091
|
+
* @function verify
|
4092
|
+
* @memberof TW.Aptos.Proto.SigningOutput
|
4093
|
+
* @static
|
4094
|
+
* @param {Object.<string,*>} message Plain object to verify
|
4095
|
+
* @returns {string|null} `null` if valid, otherwise the reason why it is not
|
4096
|
+
*/
|
4097
|
+
SigningOutput.verify = function verify(message) {
|
4098
|
+
if (typeof message !== "object" || message === null)
|
4099
|
+
return "object expected";
|
4100
|
+
if (message.rawTxn != null && message.hasOwnProperty("rawTxn"))
|
4101
|
+
if (!(message.rawTxn && typeof message.rawTxn.length === "number" || $util.isString(message.rawTxn)))
|
4102
|
+
return "rawTxn: buffer expected";
|
4103
|
+
if (message.authenticator != null && message.hasOwnProperty("authenticator")) {
|
4104
|
+
var error = $root.TW.Aptos.Proto.TransactionAuthenticator.verify(message.authenticator);
|
4105
|
+
if (error)
|
4106
|
+
return "authenticator." + error;
|
4107
|
+
}
|
4108
|
+
if (message.encoded != null && message.hasOwnProperty("encoded"))
|
4109
|
+
if (!(message.encoded && typeof message.encoded.length === "number" || $util.isString(message.encoded)))
|
4110
|
+
return "encoded: buffer expected";
|
4111
|
+
if (message.json != null && message.hasOwnProperty("json"))
|
4112
|
+
if (!$util.isString(message.json))
|
4113
|
+
return "json: string expected";
|
4114
|
+
return null;
|
4115
|
+
};
|
4116
|
+
|
4117
|
+
/**
|
4118
|
+
* Creates a SigningOutput message from a plain object. Also converts values to their respective internal types.
|
4119
|
+
* @function fromObject
|
4120
|
+
* @memberof TW.Aptos.Proto.SigningOutput
|
4121
|
+
* @static
|
4122
|
+
* @param {Object.<string,*>} object Plain object
|
4123
|
+
* @returns {TW.Aptos.Proto.SigningOutput} SigningOutput
|
4124
|
+
*/
|
4125
|
+
SigningOutput.fromObject = function fromObject(object) {
|
4126
|
+
if (object instanceof $root.TW.Aptos.Proto.SigningOutput)
|
4127
|
+
return object;
|
4128
|
+
var message = new $root.TW.Aptos.Proto.SigningOutput();
|
4129
|
+
if (object.rawTxn != null)
|
4130
|
+
if (typeof object.rawTxn === "string")
|
4131
|
+
$util.base64.decode(object.rawTxn, message.rawTxn = $util.newBuffer($util.base64.length(object.rawTxn)), 0);
|
4132
|
+
else if (object.rawTxn.length)
|
4133
|
+
message.rawTxn = object.rawTxn;
|
4134
|
+
if (object.authenticator != null) {
|
4135
|
+
if (typeof object.authenticator !== "object")
|
4136
|
+
throw TypeError(".TW.Aptos.Proto.SigningOutput.authenticator: object expected");
|
4137
|
+
message.authenticator = $root.TW.Aptos.Proto.TransactionAuthenticator.fromObject(object.authenticator);
|
4138
|
+
}
|
4139
|
+
if (object.encoded != null)
|
4140
|
+
if (typeof object.encoded === "string")
|
4141
|
+
$util.base64.decode(object.encoded, message.encoded = $util.newBuffer($util.base64.length(object.encoded)), 0);
|
4142
|
+
else if (object.encoded.length)
|
4143
|
+
message.encoded = object.encoded;
|
4144
|
+
if (object.json != null)
|
4145
|
+
message.json = String(object.json);
|
4146
|
+
return message;
|
4147
|
+
};
|
4148
|
+
|
4149
|
+
/**
|
4150
|
+
* Creates a plain object from a SigningOutput message. Also converts values to other types if specified.
|
4151
|
+
* @function toObject
|
4152
|
+
* @memberof TW.Aptos.Proto.SigningOutput
|
4153
|
+
* @static
|
4154
|
+
* @param {TW.Aptos.Proto.SigningOutput} message SigningOutput
|
4155
|
+
* @param {$protobuf.IConversionOptions} [options] Conversion options
|
4156
|
+
* @returns {Object.<string,*>} Plain object
|
4157
|
+
*/
|
4158
|
+
SigningOutput.toObject = function toObject(message, options) {
|
4159
|
+
if (!options)
|
4160
|
+
options = {};
|
4161
|
+
var object = {};
|
4162
|
+
if (options.defaults) {
|
4163
|
+
if (options.bytes === String)
|
4164
|
+
object.rawTxn = "";
|
4165
|
+
else {
|
4166
|
+
object.rawTxn = [];
|
4167
|
+
if (options.bytes !== Array)
|
4168
|
+
object.rawTxn = $util.newBuffer(object.rawTxn);
|
4169
|
+
}
|
4170
|
+
object.authenticator = null;
|
4171
|
+
if (options.bytes === String)
|
4172
|
+
object.encoded = "";
|
4173
|
+
else {
|
4174
|
+
object.encoded = [];
|
4175
|
+
if (options.bytes !== Array)
|
4176
|
+
object.encoded = $util.newBuffer(object.encoded);
|
4177
|
+
}
|
4178
|
+
object.json = "";
|
4179
|
+
}
|
4180
|
+
if (message.rawTxn != null && message.hasOwnProperty("rawTxn"))
|
4181
|
+
object.rawTxn = options.bytes === String ? $util.base64.encode(message.rawTxn, 0, message.rawTxn.length) : options.bytes === Array ? Array.prototype.slice.call(message.rawTxn) : message.rawTxn;
|
4182
|
+
if (message.authenticator != null && message.hasOwnProperty("authenticator"))
|
4183
|
+
object.authenticator = $root.TW.Aptos.Proto.TransactionAuthenticator.toObject(message.authenticator, options);
|
4184
|
+
if (message.encoded != null && message.hasOwnProperty("encoded"))
|
4185
|
+
object.encoded = options.bytes === String ? $util.base64.encode(message.encoded, 0, message.encoded.length) : options.bytes === Array ? Array.prototype.slice.call(message.encoded) : message.encoded;
|
4186
|
+
if (message.json != null && message.hasOwnProperty("json"))
|
4187
|
+
object.json = message.json;
|
4188
|
+
return object;
|
4189
|
+
};
|
4190
|
+
|
4191
|
+
/**
|
4192
|
+
* Converts this SigningOutput to JSON.
|
4193
|
+
* @function toJSON
|
4194
|
+
* @memberof TW.Aptos.Proto.SigningOutput
|
4195
|
+
* @instance
|
4196
|
+
* @returns {Object.<string,*>} JSON object
|
4197
|
+
*/
|
4198
|
+
SigningOutput.prototype.toJSON = function toJSON() {
|
4199
|
+
return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
|
4200
|
+
};
|
4201
|
+
|
4202
|
+
return SigningOutput;
|
4203
|
+
})();
|
4204
|
+
|
4205
|
+
return Proto;
|
4206
|
+
})();
|
4207
|
+
|
4208
|
+
return Aptos;
|
4209
|
+
})();
|
4210
|
+
|
2469
4211
|
TW.Binance = (function() {
|
2470
4212
|
|
2471
4213
|
/**
|
@@ -3062,137 +4804,6 @@
|
|
3062
4804
|
return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
|
3063
4805
|
};
|
3064
4806
|
|
3065
|
-
Signature.PubKey = (function() {
|
3066
|
-
|
3067
|
-
/**
|
3068
|
-
* Properties of a PubKey.
|
3069
|
-
* @memberof TW.Binance.Proto.Signature
|
3070
|
-
* @interface IPubKey
|
3071
|
-
*/
|
3072
|
-
|
3073
|
-
/**
|
3074
|
-
* Constructs a new PubKey.
|
3075
|
-
* @memberof TW.Binance.Proto.Signature
|
3076
|
-
* @classdesc Represents a PubKey.
|
3077
|
-
* @implements IPubKey
|
3078
|
-
* @constructor
|
3079
|
-
* @param {TW.Binance.Proto.Signature.IPubKey=} [properties] Properties to set
|
3080
|
-
*/
|
3081
|
-
function PubKey(properties) {
|
3082
|
-
if (properties)
|
3083
|
-
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
|
3084
|
-
if (properties[keys[i]] != null)
|
3085
|
-
this[keys[i]] = properties[keys[i]];
|
3086
|
-
}
|
3087
|
-
|
3088
|
-
/**
|
3089
|
-
* Creates a new PubKey instance using the specified properties.
|
3090
|
-
* @function create
|
3091
|
-
* @memberof TW.Binance.Proto.Signature.PubKey
|
3092
|
-
* @static
|
3093
|
-
* @param {TW.Binance.Proto.Signature.IPubKey=} [properties] Properties to set
|
3094
|
-
* @returns {TW.Binance.Proto.Signature.PubKey} PubKey instance
|
3095
|
-
*/
|
3096
|
-
PubKey.create = function create(properties) {
|
3097
|
-
return new PubKey(properties);
|
3098
|
-
};
|
3099
|
-
|
3100
|
-
/**
|
3101
|
-
* Encodes the specified PubKey message. Does not implicitly {@link TW.Binance.Proto.Signature.PubKey.verify|verify} messages.
|
3102
|
-
* @function encode
|
3103
|
-
* @memberof TW.Binance.Proto.Signature.PubKey
|
3104
|
-
* @static
|
3105
|
-
* @param {TW.Binance.Proto.Signature.IPubKey} message PubKey message or plain object to encode
|
3106
|
-
* @param {$protobuf.Writer} [writer] Writer to encode to
|
3107
|
-
* @returns {$protobuf.Writer} Writer
|
3108
|
-
*/
|
3109
|
-
PubKey.encode = function encode(message, writer) {
|
3110
|
-
if (!writer)
|
3111
|
-
writer = $Writer.create();
|
3112
|
-
return writer;
|
3113
|
-
};
|
3114
|
-
|
3115
|
-
/**
|
3116
|
-
* Decodes a PubKey message from the specified reader or buffer.
|
3117
|
-
* @function decode
|
3118
|
-
* @memberof TW.Binance.Proto.Signature.PubKey
|
3119
|
-
* @static
|
3120
|
-
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
3121
|
-
* @param {number} [length] Message length if known beforehand
|
3122
|
-
* @returns {TW.Binance.Proto.Signature.PubKey} PubKey
|
3123
|
-
* @throws {Error} If the payload is not a reader or valid buffer
|
3124
|
-
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
3125
|
-
*/
|
3126
|
-
PubKey.decode = function decode(reader, length) {
|
3127
|
-
if (!(reader instanceof $Reader))
|
3128
|
-
reader = $Reader.create(reader);
|
3129
|
-
var end = length === undefined ? reader.len : reader.pos + length, message = new $root.TW.Binance.Proto.Signature.PubKey();
|
3130
|
-
while (reader.pos < end) {
|
3131
|
-
var tag = reader.uint32();
|
3132
|
-
switch (tag >>> 3) {
|
3133
|
-
default:
|
3134
|
-
reader.skipType(tag & 7);
|
3135
|
-
break;
|
3136
|
-
}
|
3137
|
-
}
|
3138
|
-
return message;
|
3139
|
-
};
|
3140
|
-
|
3141
|
-
/**
|
3142
|
-
* Verifies a PubKey message.
|
3143
|
-
* @function verify
|
3144
|
-
* @memberof TW.Binance.Proto.Signature.PubKey
|
3145
|
-
* @static
|
3146
|
-
* @param {Object.<string,*>} message Plain object to verify
|
3147
|
-
* @returns {string|null} `null` if valid, otherwise the reason why it is not
|
3148
|
-
*/
|
3149
|
-
PubKey.verify = function verify(message) {
|
3150
|
-
if (typeof message !== "object" || message === null)
|
3151
|
-
return "object expected";
|
3152
|
-
return null;
|
3153
|
-
};
|
3154
|
-
|
3155
|
-
/**
|
3156
|
-
* Creates a PubKey message from a plain object. Also converts values to their respective internal types.
|
3157
|
-
* @function fromObject
|
3158
|
-
* @memberof TW.Binance.Proto.Signature.PubKey
|
3159
|
-
* @static
|
3160
|
-
* @param {Object.<string,*>} object Plain object
|
3161
|
-
* @returns {TW.Binance.Proto.Signature.PubKey} PubKey
|
3162
|
-
*/
|
3163
|
-
PubKey.fromObject = function fromObject(object) {
|
3164
|
-
if (object instanceof $root.TW.Binance.Proto.Signature.PubKey)
|
3165
|
-
return object;
|
3166
|
-
return new $root.TW.Binance.Proto.Signature.PubKey();
|
3167
|
-
};
|
3168
|
-
|
3169
|
-
/**
|
3170
|
-
* Creates a plain object from a PubKey message. Also converts values to other types if specified.
|
3171
|
-
* @function toObject
|
3172
|
-
* @memberof TW.Binance.Proto.Signature.PubKey
|
3173
|
-
* @static
|
3174
|
-
* @param {TW.Binance.Proto.Signature.PubKey} message PubKey
|
3175
|
-
* @param {$protobuf.IConversionOptions} [options] Conversion options
|
3176
|
-
* @returns {Object.<string,*>} Plain object
|
3177
|
-
*/
|
3178
|
-
PubKey.toObject = function toObject() {
|
3179
|
-
return {};
|
3180
|
-
};
|
3181
|
-
|
3182
|
-
/**
|
3183
|
-
* Converts this PubKey to JSON.
|
3184
|
-
* @function toJSON
|
3185
|
-
* @memberof TW.Binance.Proto.Signature.PubKey
|
3186
|
-
* @instance
|
3187
|
-
* @returns {Object.<string,*>} JSON object
|
3188
|
-
*/
|
3189
|
-
PubKey.prototype.toJSON = function toJSON() {
|
3190
|
-
return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
|
3191
|
-
};
|
3192
|
-
|
3193
|
-
return PubKey;
|
3194
|
-
})();
|
3195
|
-
|
3196
4807
|
return Signature;
|
3197
4808
|
})();
|
3198
4809
|
|
@@ -9723,8 +11334,8 @@
|
|
9723
11334
|
* @memberof TW.Binance.Proto
|
9724
11335
|
* @interface ISigningOutput
|
9725
11336
|
* @property {Uint8Array|null} [encoded] SigningOutput encoded
|
9726
|
-
* @property {TW.Common.Proto.SigningError|null} [error] error
|
9727
|
-
* @property {string|null} [errorMessage]
|
11337
|
+
* @property {TW.Common.Proto.SigningError|null} [error] SigningOutput error
|
11338
|
+
* @property {string|null} [errorMessage] SigningOutput errorMessage
|
9728
11339
|
*/
|
9729
11340
|
|
9730
11341
|
/**
|
@@ -9751,7 +11362,7 @@
|
|
9751
11362
|
SigningOutput.prototype.encoded = $util.newBuffer([]);
|
9752
11363
|
|
9753
11364
|
/**
|
9754
|
-
* error
|
11365
|
+
* SigningOutput error.
|
9755
11366
|
* @member {TW.Common.Proto.SigningError} error
|
9756
11367
|
* @memberof TW.Binance.Proto.SigningOutput
|
9757
11368
|
* @instance
|
@@ -9759,7 +11370,7 @@
|
|
9759
11370
|
SigningOutput.prototype.error = 0;
|
9760
11371
|
|
9761
11372
|
/**
|
9762
|
-
*
|
11373
|
+
* SigningOutput errorMessage.
|
9763
11374
|
* @member {string} errorMessage
|
9764
11375
|
* @memberof TW.Binance.Proto.SigningOutput
|
9765
11376
|
* @instance
|
@@ -12765,7 +14376,7 @@
|
|
12765
14376
|
/**
|
12766
14377
|
* Constructs a new HashPublicKey.
|
12767
14378
|
* @memberof TW.Bitcoin.Proto
|
12768
|
-
* @classdesc
|
14379
|
+
* @classdesc Pre-image hash to be used for signing
|
12769
14380
|
* @implements IHashPublicKey
|
12770
14381
|
* @constructor
|
12771
14382
|
* @param {TW.Bitcoin.Proto.IHashPublicKey=} [properties] Properties to set
|
@@ -23676,12 +25287,12 @@
|
|
23676
25287
|
* Properties of a Transaction.
|
23677
25288
|
* @memberof TW.Decred.Proto
|
23678
25289
|
* @interface ITransaction
|
23679
|
-
* @property {number|null} [serializeType]
|
23680
|
-
* @property {number|null} [version] Transaction
|
25290
|
+
* @property {number|null} [serializeType] Transaction serializeType
|
25291
|
+
* @property {number|null} [version] Transaction version
|
23681
25292
|
* @property {Array.<TW.Decred.Proto.ITransactionInput>|null} [inputs] Transaction inputs
|
23682
25293
|
* @property {Array.<TW.Decred.Proto.ITransactionOutput>|null} [outputs] Transaction outputs
|
23683
|
-
* @property {number|null} [lockTime]
|
23684
|
-
* @property {number|null} [expiry]
|
25294
|
+
* @property {number|null} [lockTime] Transaction lockTime
|
25295
|
+
* @property {number|null} [expiry] Transaction expiry
|
23685
25296
|
*/
|
23686
25297
|
|
23687
25298
|
/**
|
@@ -23702,7 +25313,7 @@
|
|
23702
25313
|
}
|
23703
25314
|
|
23704
25315
|
/**
|
23705
|
-
*
|
25316
|
+
* Transaction serializeType.
|
23706
25317
|
* @member {number} serializeType
|
23707
25318
|
* @memberof TW.Decred.Proto.Transaction
|
23708
25319
|
* @instance
|
@@ -23710,7 +25321,7 @@
|
|
23710
25321
|
Transaction.prototype.serializeType = 0;
|
23711
25322
|
|
23712
25323
|
/**
|
23713
|
-
* Transaction
|
25324
|
+
* Transaction version.
|
23714
25325
|
* @member {number} version
|
23715
25326
|
* @memberof TW.Decred.Proto.Transaction
|
23716
25327
|
* @instance
|
@@ -23734,7 +25345,7 @@
|
|
23734
25345
|
Transaction.prototype.outputs = $util.emptyArray;
|
23735
25346
|
|
23736
25347
|
/**
|
23737
|
-
*
|
25348
|
+
* Transaction lockTime.
|
23738
25349
|
* @member {number} lockTime
|
23739
25350
|
* @memberof TW.Decred.Proto.Transaction
|
23740
25351
|
* @instance
|
@@ -23742,7 +25353,7 @@
|
|
23742
25353
|
Transaction.prototype.lockTime = 0;
|
23743
25354
|
|
23744
25355
|
/**
|
23745
|
-
*
|
25356
|
+
* Transaction expiry.
|
23746
25357
|
* @member {number} expiry
|
23747
25358
|
* @memberof TW.Decred.Proto.Transaction
|
23748
25359
|
* @instance
|
@@ -24287,7 +25898,7 @@
|
|
24287
25898
|
* @memberof TW.Decred.Proto
|
24288
25899
|
* @interface ITransactionOutput
|
24289
25900
|
* @property {Long|null} [value] TransactionOutput value
|
24290
|
-
* @property {number|null} [version]
|
25901
|
+
* @property {number|null} [version] TransactionOutput version
|
24291
25902
|
* @property {Uint8Array|null} [script] TransactionOutput script
|
24292
25903
|
*/
|
24293
25904
|
|
@@ -24315,7 +25926,7 @@
|
|
24315
25926
|
TransactionOutput.prototype.value = $util.Long ? $util.Long.fromBits(0,0,false) : 0;
|
24316
25927
|
|
24317
25928
|
/**
|
24318
|
-
*
|
25929
|
+
* TransactionOutput version.
|
24319
25930
|
* @member {number} version
|
24320
25931
|
* @memberof TW.Decred.Proto.TransactionOutput
|
24321
25932
|
* @instance
|
@@ -29706,8 +31317,8 @@
|
|
29706
31317
|
* @property {Uint8Array|null} [r] SigningOutput r
|
29707
31318
|
* @property {Uint8Array|null} [s] SigningOutput s
|
29708
31319
|
* @property {Uint8Array|null} [data] SigningOutput data
|
29709
|
-
* @property {TW.Common.Proto.SigningError|null} [error] error
|
29710
|
-
* @property {string|null} [errorMessage]
|
31320
|
+
* @property {TW.Common.Proto.SigningError|null} [error] SigningOutput error
|
31321
|
+
* @property {string|null} [errorMessage] SigningOutput errorMessage
|
29711
31322
|
*/
|
29712
31323
|
|
29713
31324
|
/**
|
@@ -29766,7 +31377,7 @@
|
|
29766
31377
|
SigningOutput.prototype.data = $util.newBuffer([]);
|
29767
31378
|
|
29768
31379
|
/**
|
29769
|
-
* error
|
31380
|
+
* SigningOutput error.
|
29770
31381
|
* @member {TW.Common.Proto.SigningError} error
|
29771
31382
|
* @memberof TW.Ethereum.Proto.SigningOutput
|
29772
31383
|
* @instance
|
@@ -29774,7 +31385,7 @@
|
|
29774
31385
|
SigningOutput.prototype.error = 0;
|
29775
31386
|
|
29776
31387
|
/**
|
29777
|
-
*
|
31388
|
+
* SigningOutput errorMessage.
|
29778
31389
|
* @member {string} errorMessage
|
29779
31390
|
* @memberof TW.Ethereum.Proto.SigningOutput
|
29780
31391
|
* @instance
|
@@ -69292,11 +70903,11 @@
|
|
69292
70903
|
* @interface ISigningInput
|
69293
70904
|
* @property {string|null} [chainId] Chain ID string, mainnet, testnet and privatenet
|
69294
70905
|
* @property {string|null} [toAddress] Recipient address
|
69295
|
-
* @property {Uint8Array|null} [thetaAmount] Theta token amount to send in wei (
|
69296
|
-
* @property {Uint8Array|null} [tfuelAmount] TFuel token amount to send in wei (
|
70906
|
+
* @property {Uint8Array|null} [thetaAmount] Theta token amount to send in wei (uint256, serialized little endian)
|
70907
|
+
* @property {Uint8Array|null} [tfuelAmount] TFuel token amount to send in wei (uint256, serialized little endian)
|
69297
70908
|
* @property {Long|null} [sequence] Sequence number of the transaction for the sender address
|
69298
|
-
* @property {Uint8Array|null} [fee] Fee amount in TFuel wei for the transaction (
|
69299
|
-
* @property {Uint8Array|null} [privateKey]
|
70909
|
+
* @property {Uint8Array|null} [fee] Fee amount in TFuel wei for the transaction (uint256, serialized little endian)
|
70910
|
+
* @property {Uint8Array|null} [privateKey] The secret private key used for signing (32 bytes).
|
69300
70911
|
*/
|
69301
70912
|
|
69302
70913
|
/**
|
@@ -69331,7 +70942,7 @@
|
|
69331
70942
|
SigningInput.prototype.toAddress = "";
|
69332
70943
|
|
69333
70944
|
/**
|
69334
|
-
* Theta token amount to send in wei (
|
70945
|
+
* Theta token amount to send in wei (uint256, serialized little endian)
|
69335
70946
|
* @member {Uint8Array} thetaAmount
|
69336
70947
|
* @memberof TW.Theta.Proto.SigningInput
|
69337
70948
|
* @instance
|
@@ -69339,7 +70950,7 @@
|
|
69339
70950
|
SigningInput.prototype.thetaAmount = $util.newBuffer([]);
|
69340
70951
|
|
69341
70952
|
/**
|
69342
|
-
* TFuel token amount to send in wei (
|
70953
|
+
* TFuel token amount to send in wei (uint256, serialized little endian)
|
69343
70954
|
* @member {Uint8Array} tfuelAmount
|
69344
70955
|
* @memberof TW.Theta.Proto.SigningInput
|
69345
70956
|
* @instance
|
@@ -69355,7 +70966,7 @@
|
|
69355
70966
|
SigningInput.prototype.sequence = $util.Long ? $util.Long.fromBits(0,0,true) : 0;
|
69356
70967
|
|
69357
70968
|
/**
|
69358
|
-
* Fee amount in TFuel wei for the transaction (
|
70969
|
+
* Fee amount in TFuel wei for the transaction (uint256, serialized little endian)
|
69359
70970
|
* @member {Uint8Array} fee
|
69360
70971
|
* @memberof TW.Theta.Proto.SigningInput
|
69361
70972
|
* @instance
|
@@ -69363,7 +70974,7 @@
|
|
69363
70974
|
SigningInput.prototype.fee = $util.newBuffer([]);
|
69364
70975
|
|
69365
70976
|
/**
|
69366
|
-
*
|
70977
|
+
* The secret private key used for signing (32 bytes).
|
69367
70978
|
* @member {Uint8Array} privateKey
|
69368
70979
|
* @memberof TW.Theta.Proto.SigningInput
|
69369
70980
|
* @instance
|
@@ -69638,7 +71249,7 @@
|
|
69638
71249
|
/**
|
69639
71250
|
* Constructs a new SigningOutput.
|
69640
71251
|
* @memberof TW.Theta.Proto
|
69641
|
-
* @classdesc
|
71252
|
+
* @classdesc Represents a SigningOutput.
|
69642
71253
|
* @implements ISigningOutput
|
69643
71254
|
* @constructor
|
69644
71255
|
* @param {TW.Theta.Proto.ISigningOutput=} [properties] Properties to set
|
@@ -75397,7 +77008,7 @@
|
|
75397
77008
|
* @memberof TW.VeChain.Proto
|
75398
77009
|
* @interface IClause
|
75399
77010
|
* @property {string|null} [to] Recipient address.
|
75400
|
-
* @property {Uint8Array|null} [value] Transaction amount
|
77011
|
+
* @property {Uint8Array|null} [value] Transaction amount (uint256, serialized little endian)
|
75401
77012
|
* @property {Uint8Array|null} [data] Payload data.
|
75402
77013
|
*/
|
75403
77014
|
|
@@ -75425,7 +77036,7 @@
|
|
75425
77036
|
Clause.prototype.to = "";
|
75426
77037
|
|
75427
77038
|
/**
|
75428
|
-
* Transaction amount
|
77039
|
+
* Transaction amount (uint256, serialized little endian)
|
75429
77040
|
* @member {Uint8Array} value
|
75430
77041
|
* @memberof TW.VeChain.Proto.Clause
|
75431
77042
|
* @instance
|
@@ -75625,7 +77236,7 @@
|
|
75625
77236
|
* @property {Long|null} [gas] Maximum amount of gas allowed to pay for the transaction.
|
75626
77237
|
* @property {Uint8Array|null} [dependsOn] ID of the transaction on which the current transaction depends.
|
75627
77238
|
* @property {Long|null} [nonce] Number set by user.
|
75628
|
-
* @property {Uint8Array|null} [privateKey]
|
77239
|
+
* @property {Uint8Array|null} [privateKey] The secret private key used for signing (32 bytes).
|
75629
77240
|
*/
|
75630
77241
|
|
75631
77242
|
/**
|
@@ -75709,7 +77320,7 @@
|
|
75709
77320
|
SigningInput.prototype.nonce = $util.Long ? $util.Long.fromBits(0,0,true) : 0;
|
75710
77321
|
|
75711
77322
|
/**
|
75712
|
-
*
|
77323
|
+
* The secret private key used for signing (32 bytes).
|
75713
77324
|
* @member {Uint8Array} privateKey
|
75714
77325
|
* @memberof TW.VeChain.Proto.SigningInput
|
75715
77326
|
* @instance
|