@typemove/sui 1.0.0-rc.19 → 1.0.0-rc.21
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/builtin/0x1.d.ts +211 -10870
- package/dist/builtin/0x1.d.ts.map +1 -1
- package/dist/builtin/0x1.js +166 -165
- package/dist/builtin/0x1.js.map +1 -1
- package/dist/builtin/0x2.d.ts +1163 -46532
- package/dist/builtin/0x2.d.ts.map +1 -1
- package/dist/builtin/0x2.js +700 -699
- package/dist/builtin/0x2.js.map +1 -1
- package/dist/builtin/0x3.d.ts +476 -13475
- package/dist/builtin/0x3.d.ts.map +1 -1
- package/dist/builtin/0x3.js +202 -201
- package/dist/builtin/0x3.js.map +1 -1
- package/dist/codegen/codegen.js +9 -8
- package/dist/codegen/codegen.js.map +1 -1
- package/dist/models.d.ts +1 -1
- package/dist/models.d.ts.map +1 -1
- package/dist/models.js.map +1 -1
- package/dist/move-coder.d.ts +1 -1
- package/dist/move-coder.d.ts.map +1 -1
- package/dist/move-coder.js +1 -5
- package/dist/move-coder.js.map +1 -1
- package/dist/sui-chain-adapter.d.ts +1 -1
- package/dist/sui-chain-adapter.d.ts.map +1 -1
- package/dist/sui-chain-adapter.js +10 -4
- package/dist/sui-chain-adapter.js.map +1 -1
- package/dist/tests/move-call.test.d.ts.map +1 -1
- package/dist/tests/move-call.test.js.map +1 -1
- package/dist/tests/move-coder.test.js.map +1 -1
- package/dist/tests/types/testnet/0x1e2b124f746a339b3cf99b9f969393a96594519aafb1d06517aacfeeae20e7a5.d.ts +25 -544
- package/dist/tests/types/testnet/0x1e2b124f746a339b3cf99b9f969393a96594519aafb1d06517aacfeeae20e7a5.d.ts.map +1 -1
- package/dist/tests/types/testnet/0x1e2b124f746a339b3cf99b9f969393a96594519aafb1d06517aacfeeae20e7a5.js +10 -9
- package/dist/tests/types/testnet/0x1e2b124f746a339b3cf99b9f969393a96594519aafb1d06517aacfeeae20e7a5.js.map +1 -1
- package/dist/tests/types/testnet/0x6c4a21e3e7e6b6d51c4604021633e1d97e24e37a696f8c082cd48f37503e602a.d.ts +250 -6489
- package/dist/tests/types/testnet/0x6c4a21e3e7e6b6d51c4604021633e1d97e24e37a696f8c082cd48f37503e602a.d.ts.map +1 -1
- package/dist/tests/types/testnet/0x6c4a21e3e7e6b6d51c4604021633e1d97e24e37a696f8c082cd48f37503e602a.js +98 -97
- package/dist/tests/types/testnet/0x6c4a21e3e7e6b6d51c4604021633e1d97e24e37a696f8c082cd48f37503e602a.js.map +1 -1
- package/dist/tests/types/testnet/0xdee9.d.ts +289 -6398
- package/dist/tests/types/testnet/0xdee9.d.ts.map +1 -1
- package/dist/tests/types/testnet/0xdee9.js +96 -95
- package/dist/tests/types/testnet/0xdee9.js.map +1 -1
- package/dist/tests/types/testnet/0xebaa2ad3eacc230f309cd933958cc52684df0a41ae7ac214d186b80f830867d2.d.ts +977 -21126
- package/dist/tests/types/testnet/0xebaa2ad3eacc230f309cd933958cc52684df0a41ae7ac214d186b80f830867d2.d.ts.map +1 -1
- package/dist/tests/types/testnet/0xebaa2ad3eacc230f309cd933958cc52684df0a41ae7ac214d186b80f830867d2.js +312 -311
- package/dist/tests/types/testnet/0xebaa2ad3eacc230f309cd933958cc52684df0a41ae7ac214d186b80f830867d2.js.map +1 -1
- package/dist/to-internal.d.ts +1 -1
- package/dist/to-internal.d.ts.map +1 -1
- package/dist/to-internal.js +2 -8
- package/dist/to-internal.js.map +1 -1
- package/package.json +5 -12
- package/src/builtin/0x1.ts +293 -297
- package/src/builtin/0x2.ts +1483 -1490
- package/src/builtin/0x3.ts +582 -589
- package/src/codegen/codegen.ts +10 -9
- package/src/models.ts +8 -14
- package/src/move-coder.ts +6 -20
- package/src/sui-chain-adapter.ts +13 -15
- package/src/tests/types/testnet/0x1e2b124f746a339b3cf99b9f969393a96594519aafb1d06517aacfeeae20e7a5.ts +27 -31
- package/src/tests/types/testnet/0x6c4a21e3e7e6b6d51c4604021633e1d97e24e37a696f8c082cd48f37503e602a.ts +276 -280
- package/src/tests/types/testnet/0xdee9.ts +303 -307
- package/src/tests/types/testnet/0xebaa2ad3eacc230f309cd933958cc52684df0a41ae7ac214d186b80f830867d2.ts +1064 -1068
- package/src/to-internal.ts +12 -32
|
@@ -5,7 +5,8 @@
|
|
|
5
5
|
import { TypeDescriptor, ANY_TYPE } from "@typemove/move";
|
|
6
6
|
import { defaultMoveCoder } from "@typemove/sui";
|
|
7
7
|
import { ZERO_ADDRESS } from "@typemove/sui";
|
|
8
|
-
import { TransactionBlock
|
|
8
|
+
import { TransactionBlock } from "@mysten/sui.js/transactions";
|
|
9
|
+
import { TransactionArgument } from "@mysten/sui.js";
|
|
9
10
|
import { _0x2 } from "@typemove/sui/builtin";
|
|
10
11
|
import { _0x1 } from "@typemove/sui/builtin";
|
|
11
12
|
export var comparator;
|
|
@@ -91,50 +92,50 @@ export var comparator;
|
|
|
91
92
|
})(builder = comparator.builder || (comparator.builder = {}));
|
|
92
93
|
let view;
|
|
93
94
|
(function (view) {
|
|
94
|
-
async function compare(
|
|
95
|
+
async function compare(client, args, typeArguments) {
|
|
95
96
|
const tx = new TransactionBlock();
|
|
96
97
|
builder.compare(tx, args, typeArguments);
|
|
97
|
-
const res = await
|
|
98
|
+
const res = await client.devInspectTransactionBlock({
|
|
98
99
|
transactionBlock: tx,
|
|
99
100
|
sender: ZERO_ADDRESS,
|
|
100
101
|
});
|
|
101
102
|
return res;
|
|
102
103
|
}
|
|
103
104
|
view.compare = compare;
|
|
104
|
-
async function compareU8Vector(
|
|
105
|
+
async function compareU8Vector(client, args) {
|
|
105
106
|
const tx = new TransactionBlock();
|
|
106
107
|
builder.compareU8Vector(tx, args);
|
|
107
|
-
const res = await
|
|
108
|
+
const res = await client.devInspectTransactionBlock({
|
|
108
109
|
transactionBlock: tx,
|
|
109
110
|
sender: ZERO_ADDRESS,
|
|
110
111
|
});
|
|
111
112
|
return res;
|
|
112
113
|
}
|
|
113
114
|
view.compareU8Vector = compareU8Vector;
|
|
114
|
-
async function isEqual(
|
|
115
|
+
async function isEqual(client, args) {
|
|
115
116
|
const tx = new TransactionBlock();
|
|
116
117
|
builder.isEqual(tx, args);
|
|
117
|
-
const res = await
|
|
118
|
+
const res = await client.devInspectTransactionBlock({
|
|
118
119
|
transactionBlock: tx,
|
|
119
120
|
sender: ZERO_ADDRESS,
|
|
120
121
|
});
|
|
121
122
|
return res;
|
|
122
123
|
}
|
|
123
124
|
view.isEqual = isEqual;
|
|
124
|
-
async function isGreaterThan(
|
|
125
|
+
async function isGreaterThan(client, args) {
|
|
125
126
|
const tx = new TransactionBlock();
|
|
126
127
|
builder.isGreaterThan(tx, args);
|
|
127
|
-
const res = await
|
|
128
|
+
const res = await client.devInspectTransactionBlock({
|
|
128
129
|
transactionBlock: tx,
|
|
129
130
|
sender: ZERO_ADDRESS,
|
|
130
131
|
});
|
|
131
132
|
return res;
|
|
132
133
|
}
|
|
133
134
|
view.isGreaterThan = isGreaterThan;
|
|
134
|
-
async function isSmallerThan(
|
|
135
|
+
async function isSmallerThan(client, args) {
|
|
135
136
|
const tx = new TransactionBlock();
|
|
136
137
|
builder.isSmallerThan(tx, args);
|
|
137
|
-
const res = await
|
|
138
|
+
const res = await client.devInspectTransactionBlock({
|
|
138
139
|
transactionBlock: tx,
|
|
139
140
|
sender: ZERO_ADDRESS,
|
|
140
141
|
});
|
|
@@ -214,60 +215,60 @@ export var math_utils;
|
|
|
214
215
|
})(builder = math_utils.builder || (math_utils.builder = {}));
|
|
215
216
|
let view;
|
|
216
217
|
(function (view) {
|
|
217
|
-
async function max(
|
|
218
|
+
async function max(client, args) {
|
|
218
219
|
const tx = new TransactionBlock();
|
|
219
220
|
builder.max(tx, args);
|
|
220
|
-
const res = await
|
|
221
|
+
const res = await client.devInspectTransactionBlock({
|
|
221
222
|
transactionBlock: tx,
|
|
222
223
|
sender: ZERO_ADDRESS,
|
|
223
224
|
});
|
|
224
225
|
return res;
|
|
225
226
|
}
|
|
226
227
|
view.max = max;
|
|
227
|
-
async function maxU64(
|
|
228
|
+
async function maxU64(client, args) {
|
|
228
229
|
const tx = new TransactionBlock();
|
|
229
230
|
builder.maxU64(tx, args);
|
|
230
|
-
const res = await
|
|
231
|
+
const res = await client.devInspectTransactionBlock({
|
|
231
232
|
transactionBlock: tx,
|
|
232
233
|
sender: ZERO_ADDRESS,
|
|
233
234
|
});
|
|
234
235
|
return res;
|
|
235
236
|
}
|
|
236
237
|
view.maxU64 = maxU64;
|
|
237
|
-
async function min(
|
|
238
|
+
async function min(client, args) {
|
|
238
239
|
const tx = new TransactionBlock();
|
|
239
240
|
builder.min(tx, args);
|
|
240
|
-
const res = await
|
|
241
|
+
const res = await client.devInspectTransactionBlock({
|
|
241
242
|
transactionBlock: tx,
|
|
242
243
|
sender: ZERO_ADDRESS,
|
|
243
244
|
});
|
|
244
245
|
return res;
|
|
245
246
|
}
|
|
246
247
|
view.min = min;
|
|
247
|
-
async function pow(
|
|
248
|
+
async function pow(client, args) {
|
|
248
249
|
const tx = new TransactionBlock();
|
|
249
250
|
builder.pow(tx, args);
|
|
250
|
-
const res = await
|
|
251
|
+
const res = await client.devInspectTransactionBlock({
|
|
251
252
|
transactionBlock: tx,
|
|
252
253
|
sender: ZERO_ADDRESS,
|
|
253
254
|
});
|
|
254
255
|
return res;
|
|
255
256
|
}
|
|
256
257
|
view.pow = pow;
|
|
257
|
-
async function sqrt(
|
|
258
|
+
async function sqrt(client, args) {
|
|
258
259
|
const tx = new TransactionBlock();
|
|
259
260
|
builder.sqrt(tx, args);
|
|
260
|
-
const res = await
|
|
261
|
+
const res = await client.devInspectTransactionBlock({
|
|
261
262
|
transactionBlock: tx,
|
|
262
263
|
sender: ZERO_ADDRESS,
|
|
263
264
|
});
|
|
264
265
|
return res;
|
|
265
266
|
}
|
|
266
267
|
view.sqrt = sqrt;
|
|
267
|
-
async function sqrtU256(
|
|
268
|
+
async function sqrtU256(client, args) {
|
|
268
269
|
const tx = new TransactionBlock();
|
|
269
270
|
builder.sqrtU256(tx, args);
|
|
270
|
-
const res = await
|
|
271
|
+
const res = await client.devInspectTransactionBlock({
|
|
271
272
|
transactionBlock: tx,
|
|
272
273
|
sender: ZERO_ADDRESS,
|
|
273
274
|
});
|
|
@@ -792,210 +793,210 @@ export var pool;
|
|
|
792
793
|
})(builder = pool.builder || (pool.builder = {}));
|
|
793
794
|
let view;
|
|
794
795
|
(function (view) {
|
|
795
|
-
async function addLiquidity(
|
|
796
|
+
async function addLiquidity(client, args, typeArguments) {
|
|
796
797
|
const tx = new TransactionBlock();
|
|
797
798
|
builder.addLiquidity(tx, args, typeArguments);
|
|
798
|
-
const res = await
|
|
799
|
+
const res = await client.devInspectTransactionBlock({
|
|
799
800
|
transactionBlock: tx,
|
|
800
801
|
sender: ZERO_ADDRESS,
|
|
801
802
|
});
|
|
802
803
|
return res;
|
|
803
804
|
}
|
|
804
805
|
view.addLiquidity = addLiquidity;
|
|
805
|
-
async function borrowMutPool(
|
|
806
|
+
async function borrowMutPool(client, args, typeArguments) {
|
|
806
807
|
const tx = new TransactionBlock();
|
|
807
808
|
builder.borrowMutPool(tx, args, typeArguments);
|
|
808
|
-
const res = await
|
|
809
|
+
const res = await client.devInspectTransactionBlock({
|
|
809
810
|
transactionBlock: tx,
|
|
810
811
|
sender: ZERO_ADDRESS,
|
|
811
812
|
});
|
|
812
813
|
return res;
|
|
813
814
|
}
|
|
814
815
|
view.borrowMutPool = borrowMutPool;
|
|
815
|
-
async function borrowPool(
|
|
816
|
+
async function borrowPool(client, args, typeArguments) {
|
|
816
817
|
const tx = new TransactionBlock();
|
|
817
818
|
builder.borrowPool(tx, args, typeArguments);
|
|
818
|
-
const res = await
|
|
819
|
+
const res = await client.devInspectTransactionBlock({
|
|
819
820
|
transactionBlock: tx,
|
|
820
821
|
sender: ZERO_ADDRESS,
|
|
821
822
|
});
|
|
822
823
|
return res;
|
|
823
824
|
}
|
|
824
825
|
view.borrowPool = borrowPool;
|
|
825
|
-
async function createPool(
|
|
826
|
+
async function createPool(client, args, typeArguments) {
|
|
826
827
|
const tx = new TransactionBlock();
|
|
827
828
|
builder.createPool(tx, args, typeArguments);
|
|
828
|
-
const res = await
|
|
829
|
+
const res = await client.devInspectTransactionBlock({
|
|
829
830
|
transactionBlock: tx,
|
|
830
831
|
sender: ZERO_ADDRESS,
|
|
831
832
|
});
|
|
832
833
|
return res;
|
|
833
834
|
}
|
|
834
835
|
view.createPool = createPool;
|
|
835
|
-
async function createPoolName(
|
|
836
|
+
async function createPoolName(client, args) {
|
|
836
837
|
const tx = new TransactionBlock();
|
|
837
838
|
builder.createPoolName(tx, args);
|
|
838
|
-
const res = await
|
|
839
|
+
const res = await client.devInspectTransactionBlock({
|
|
839
840
|
transactionBlock: tx,
|
|
840
841
|
sender: ZERO_ADDRESS,
|
|
841
842
|
});
|
|
842
843
|
return res;
|
|
843
844
|
}
|
|
844
845
|
view.createPoolName = createPoolName;
|
|
845
|
-
async function getAmounts(
|
|
846
|
+
async function getAmounts(client, args, typeArguments) {
|
|
846
847
|
const tx = new TransactionBlock();
|
|
847
848
|
builder.getAmounts(tx, args, typeArguments);
|
|
848
|
-
const res = await
|
|
849
|
+
const res = await client.devInspectTransactionBlock({
|
|
849
850
|
transactionBlock: tx,
|
|
850
851
|
sender: ZERO_ADDRESS,
|
|
851
852
|
});
|
|
852
853
|
return res;
|
|
853
854
|
}
|
|
854
855
|
view.getAmounts = getAmounts;
|
|
855
|
-
async function getInputAmount(
|
|
856
|
+
async function getInputAmount(client, args, typeArguments) {
|
|
856
857
|
const tx = new TransactionBlock();
|
|
857
858
|
builder.getInputAmount(tx, args, typeArguments);
|
|
858
|
-
const res = await
|
|
859
|
+
const res = await client.devInspectTransactionBlock({
|
|
859
860
|
transactionBlock: tx,
|
|
860
861
|
sender: ZERO_ADDRESS,
|
|
861
862
|
});
|
|
862
863
|
return res;
|
|
863
864
|
}
|
|
864
865
|
view.getInputAmount = getInputAmount;
|
|
865
|
-
async function getOutputAmount(
|
|
866
|
+
async function getOutputAmount(client, args, typeArguments) {
|
|
866
867
|
const tx = new TransactionBlock();
|
|
867
868
|
builder.getOutputAmount(tx, args, typeArguments);
|
|
868
|
-
const res = await
|
|
869
|
+
const res = await client.devInspectTransactionBlock({
|
|
869
870
|
transactionBlock: tx,
|
|
870
871
|
sender: ZERO_ADDRESS,
|
|
871
872
|
});
|
|
872
873
|
return res;
|
|
873
874
|
}
|
|
874
875
|
view.getOutputAmount = getOutputAmount;
|
|
875
|
-
async function getPoolData(
|
|
876
|
+
async function getPoolData(client, args, typeArguments) {
|
|
876
877
|
const tx = new TransactionBlock();
|
|
877
878
|
builder.getPoolData(tx, args, typeArguments);
|
|
878
|
-
const res = await
|
|
879
|
+
const res = await client.devInspectTransactionBlock({
|
|
879
880
|
transactionBlock: tx,
|
|
880
881
|
sender: ZERO_ADDRESS,
|
|
881
882
|
});
|
|
882
883
|
return res;
|
|
883
884
|
}
|
|
884
885
|
view.getPoolData = getPoolData;
|
|
885
|
-
async function isPoolCreated(
|
|
886
|
+
async function isPoolCreated(client, args, typeArguments) {
|
|
886
887
|
const tx = new TransactionBlock();
|
|
887
888
|
builder.isPoolCreated(tx, args, typeArguments);
|
|
888
|
-
const res = await
|
|
889
|
+
const res = await client.devInspectTransactionBlock({
|
|
889
890
|
transactionBlock: tx,
|
|
890
891
|
sender: ZERO_ADDRESS,
|
|
891
892
|
});
|
|
892
893
|
return res;
|
|
893
894
|
}
|
|
894
895
|
view.isPoolCreated = isPoolCreated;
|
|
895
|
-
async function isPoolCreatedSorted(
|
|
896
|
+
async function isPoolCreatedSorted(client, args, typeArguments) {
|
|
896
897
|
const tx = new TransactionBlock();
|
|
897
898
|
builder.isPoolCreatedSorted(tx, args, typeArguments);
|
|
898
|
-
const res = await
|
|
899
|
+
const res = await client.devInspectTransactionBlock({
|
|
899
900
|
transactionBlock: tx,
|
|
900
901
|
sender: ZERO_ADDRESS,
|
|
901
902
|
});
|
|
902
903
|
return res;
|
|
903
904
|
}
|
|
904
905
|
view.isPoolCreatedSorted = isPoolCreatedSorted;
|
|
905
|
-
async function processSwapExactInput(
|
|
906
|
+
async function processSwapExactInput(client, args, typeArguments) {
|
|
906
907
|
const tx = new TransactionBlock();
|
|
907
908
|
builder.processSwapExactInput(tx, args, typeArguments);
|
|
908
|
-
const res = await
|
|
909
|
+
const res = await client.devInspectTransactionBlock({
|
|
909
910
|
transactionBlock: tx,
|
|
910
911
|
sender: ZERO_ADDRESS,
|
|
911
912
|
});
|
|
912
913
|
return res;
|
|
913
914
|
}
|
|
914
915
|
view.processSwapExactInput = processSwapExactInput;
|
|
915
|
-
async function processSwapExactOutput(
|
|
916
|
+
async function processSwapExactOutput(client, args, typeArguments) {
|
|
916
917
|
const tx = new TransactionBlock();
|
|
917
918
|
builder.processSwapExactOutput(tx, args, typeArguments);
|
|
918
|
-
const res = await
|
|
919
|
+
const res = await client.devInspectTransactionBlock({
|
|
919
920
|
transactionBlock: tx,
|
|
920
921
|
sender: ZERO_ADDRESS,
|
|
921
922
|
});
|
|
922
923
|
return res;
|
|
923
924
|
}
|
|
924
925
|
view.processSwapExactOutput = processSwapExactOutput;
|
|
925
|
-
async function removeLiquidity(
|
|
926
|
+
async function removeLiquidity(client, args, typeArguments) {
|
|
926
927
|
const tx = new TransactionBlock();
|
|
927
928
|
builder.removeLiquidity(tx, args, typeArguments);
|
|
928
|
-
const res = await
|
|
929
|
+
const res = await client.devInspectTransactionBlock({
|
|
929
930
|
transactionBlock: tx,
|
|
930
931
|
sender: ZERO_ADDRESS,
|
|
931
932
|
});
|
|
932
933
|
return res;
|
|
933
934
|
}
|
|
934
935
|
view.removeLiquidity = removeLiquidity;
|
|
935
|
-
async function setFeeTo_(
|
|
936
|
+
async function setFeeTo_(client, args) {
|
|
936
937
|
const tx = new TransactionBlock();
|
|
937
938
|
builder.setFeeTo_(tx, args);
|
|
938
|
-
const res = await
|
|
939
|
+
const res = await client.devInspectTransactionBlock({
|
|
939
940
|
transactionBlock: tx,
|
|
940
941
|
sender: ZERO_ADDRESS,
|
|
941
942
|
});
|
|
942
943
|
return res;
|
|
943
944
|
}
|
|
944
945
|
view.setFeeTo_ = setFeeTo_;
|
|
945
|
-
async function swapExactFirstToSecond(
|
|
946
|
+
async function swapExactFirstToSecond(client, args, typeArguments) {
|
|
946
947
|
const tx = new TransactionBlock();
|
|
947
948
|
builder.swapExactFirstToSecond(tx, args, typeArguments);
|
|
948
|
-
const res = await
|
|
949
|
+
const res = await client.devInspectTransactionBlock({
|
|
949
950
|
transactionBlock: tx,
|
|
950
951
|
sender: ZERO_ADDRESS,
|
|
951
952
|
});
|
|
952
953
|
return res;
|
|
953
954
|
}
|
|
954
955
|
view.swapExactFirstToSecond = swapExactFirstToSecond;
|
|
955
|
-
async function swapExactSecondToFirst(
|
|
956
|
+
async function swapExactSecondToFirst(client, args, typeArguments) {
|
|
956
957
|
const tx = new TransactionBlock();
|
|
957
958
|
builder.swapExactSecondToFirst(tx, args, typeArguments);
|
|
958
|
-
const res = await
|
|
959
|
+
const res = await client.devInspectTransactionBlock({
|
|
959
960
|
transactionBlock: tx,
|
|
960
961
|
sender: ZERO_ADDRESS,
|
|
961
962
|
});
|
|
962
963
|
return res;
|
|
963
964
|
}
|
|
964
965
|
view.swapExactSecondToFirst = swapExactSecondToFirst;
|
|
965
|
-
async function swapFirstToExactSecond(
|
|
966
|
+
async function swapFirstToExactSecond(client, args, typeArguments) {
|
|
966
967
|
const tx = new TransactionBlock();
|
|
967
968
|
builder.swapFirstToExactSecond(tx, args, typeArguments);
|
|
968
|
-
const res = await
|
|
969
|
+
const res = await client.devInspectTransactionBlock({
|
|
969
970
|
transactionBlock: tx,
|
|
970
971
|
sender: ZERO_ADDRESS,
|
|
971
972
|
});
|
|
972
973
|
return res;
|
|
973
974
|
}
|
|
974
975
|
view.swapFirstToExactSecond = swapFirstToExactSecond;
|
|
975
|
-
async function swapSecondToExactFirst(
|
|
976
|
+
async function swapSecondToExactFirst(client, args, typeArguments) {
|
|
976
977
|
const tx = new TransactionBlock();
|
|
977
978
|
builder.swapSecondToExactFirst(tx, args, typeArguments);
|
|
978
|
-
const res = await
|
|
979
|
+
const res = await client.devInspectTransactionBlock({
|
|
979
980
|
transactionBlock: tx,
|
|
980
981
|
sender: ZERO_ADDRESS,
|
|
981
982
|
});
|
|
982
983
|
return res;
|
|
983
984
|
}
|
|
984
985
|
view.swapSecondToExactFirst = swapSecondToExactFirst;
|
|
985
|
-
async function zapInFirst(
|
|
986
|
+
async function zapInFirst(client, args, typeArguments) {
|
|
986
987
|
const tx = new TransactionBlock();
|
|
987
988
|
builder.zapInFirst(tx, args, typeArguments);
|
|
988
|
-
const res = await
|
|
989
|
+
const res = await client.devInspectTransactionBlock({
|
|
989
990
|
transactionBlock: tx,
|
|
990
991
|
sender: ZERO_ADDRESS,
|
|
991
992
|
});
|
|
992
993
|
return res;
|
|
993
994
|
}
|
|
994
995
|
view.zapInFirst = zapInFirst;
|
|
995
|
-
async function zapInSecond(
|
|
996
|
+
async function zapInSecond(client, args, typeArguments) {
|
|
996
997
|
const tx = new TransactionBlock();
|
|
997
998
|
builder.zapInSecond(tx, args, typeArguments);
|
|
998
|
-
const res = await
|
|
999
|
+
const res = await client.devInspectTransactionBlock({
|
|
999
1000
|
transactionBlock: tx,
|
|
1000
1001
|
sender: ZERO_ADDRESS,
|
|
1001
1002
|
});
|
|
@@ -1124,80 +1125,80 @@ export var pool_utils;
|
|
|
1124
1125
|
})(builder = pool_utils.builder || (pool_utils.builder = {}));
|
|
1125
1126
|
let view;
|
|
1126
1127
|
(function (view) {
|
|
1127
|
-
async function executeReturnToken(
|
|
1128
|
+
async function executeReturnToken(client, args, typeArguments) {
|
|
1128
1129
|
const tx = new TransactionBlock();
|
|
1129
1130
|
builder.executeReturnToken(tx, args, typeArguments);
|
|
1130
|
-
const res = await
|
|
1131
|
+
const res = await client.devInspectTransactionBlock({
|
|
1131
1132
|
transactionBlock: tx,
|
|
1132
1133
|
sender: ZERO_ADDRESS,
|
|
1133
1134
|
});
|
|
1134
1135
|
return res;
|
|
1135
1136
|
}
|
|
1136
1137
|
view.executeReturnToken = executeReturnToken;
|
|
1137
|
-
async function getInputPrice(
|
|
1138
|
+
async function getInputPrice(client, args) {
|
|
1138
1139
|
const tx = new TransactionBlock();
|
|
1139
1140
|
builder.getInputPrice(tx, args);
|
|
1140
|
-
const res = await
|
|
1141
|
+
const res = await client.devInspectTransactionBlock({
|
|
1141
1142
|
transactionBlock: tx,
|
|
1142
1143
|
sender: ZERO_ADDRESS,
|
|
1143
1144
|
});
|
|
1144
1145
|
return res;
|
|
1145
1146
|
}
|
|
1146
1147
|
view.getInputPrice = getInputPrice;
|
|
1147
|
-
async function getOptimalZapInAmount(
|
|
1148
|
+
async function getOptimalZapInAmount(client, args) {
|
|
1148
1149
|
const tx = new TransactionBlock();
|
|
1149
1150
|
builder.getOptimalZapInAmount(tx, args);
|
|
1150
|
-
const res = await
|
|
1151
|
+
const res = await client.devInspectTransactionBlock({
|
|
1151
1152
|
transactionBlock: tx,
|
|
1152
1153
|
sender: ZERO_ADDRESS,
|
|
1153
1154
|
});
|
|
1154
1155
|
return res;
|
|
1155
1156
|
}
|
|
1156
1157
|
view.getOptimalZapInAmount = getOptimalZapInAmount;
|
|
1157
|
-
async function getOutputPrice(
|
|
1158
|
+
async function getOutputPrice(client, args) {
|
|
1158
1159
|
const tx = new TransactionBlock();
|
|
1159
1160
|
builder.getOutputPrice(tx, args);
|
|
1160
|
-
const res = await
|
|
1161
|
+
const res = await client.devInspectTransactionBlock({
|
|
1161
1162
|
transactionBlock: tx,
|
|
1162
1163
|
sender: ZERO_ADDRESS,
|
|
1163
1164
|
});
|
|
1164
1165
|
return res;
|
|
1165
1166
|
}
|
|
1166
1167
|
view.getOutputPrice = getOutputPrice;
|
|
1167
|
-
async function getTripleType(
|
|
1168
|
+
async function getTripleType(client, args, typeArguments) {
|
|
1168
1169
|
const tx = new TransactionBlock();
|
|
1169
1170
|
builder.getTripleType(tx, args, typeArguments);
|
|
1170
|
-
const res = await
|
|
1171
|
+
const res = await client.devInspectTransactionBlock({
|
|
1171
1172
|
transactionBlock: tx,
|
|
1172
1173
|
sender: ZERO_ADDRESS,
|
|
1173
1174
|
});
|
|
1174
1175
|
return res;
|
|
1175
1176
|
}
|
|
1176
1177
|
view.getTripleType = getTripleType;
|
|
1177
|
-
async function getType(
|
|
1178
|
+
async function getType(client, args, typeArguments) {
|
|
1178
1179
|
const tx = new TransactionBlock();
|
|
1179
1180
|
builder.getType(tx, args, typeArguments);
|
|
1180
|
-
const res = await
|
|
1181
|
+
const res = await client.devInspectTransactionBlock({
|
|
1181
1182
|
transactionBlock: tx,
|
|
1182
1183
|
sender: ZERO_ADDRESS,
|
|
1183
1184
|
});
|
|
1184
1185
|
return res;
|
|
1185
1186
|
}
|
|
1186
1187
|
view.getType = getType;
|
|
1187
|
-
async function quote(
|
|
1188
|
+
async function quote(client, args) {
|
|
1188
1189
|
const tx = new TransactionBlock();
|
|
1189
1190
|
builder.quote(tx, args);
|
|
1190
|
-
const res = await
|
|
1191
|
+
const res = await client.devInspectTransactionBlock({
|
|
1191
1192
|
transactionBlock: tx,
|
|
1192
1193
|
sender: ZERO_ADDRESS,
|
|
1193
1194
|
});
|
|
1194
1195
|
return res;
|
|
1195
1196
|
}
|
|
1196
1197
|
view.quote = quote;
|
|
1197
|
-
async function sortTokenType(
|
|
1198
|
+
async function sortTokenType(client, args) {
|
|
1198
1199
|
const tx = new TransactionBlock();
|
|
1199
1200
|
builder.sortTokenType(tx, args);
|
|
1200
|
-
const res = await
|
|
1201
|
+
const res = await client.devInspectTransactionBlock({
|
|
1201
1202
|
transactionBlock: tx,
|
|
1202
1203
|
sender: ZERO_ADDRESS,
|
|
1203
1204
|
});
|
|
@@ -1449,80 +1450,80 @@ export var router;
|
|
|
1449
1450
|
})(builder = router.builder || (router.builder = {}));
|
|
1450
1451
|
let view;
|
|
1451
1452
|
(function (view) {
|
|
1452
|
-
async function addLiquidity_(
|
|
1453
|
+
async function addLiquidity_(client, args, typeArguments) {
|
|
1453
1454
|
const tx = new TransactionBlock();
|
|
1454
1455
|
builder.addLiquidity_(tx, args, typeArguments);
|
|
1455
|
-
const res = await
|
|
1456
|
+
const res = await client.devInspectTransactionBlock({
|
|
1456
1457
|
transactionBlock: tx,
|
|
1457
1458
|
sender: ZERO_ADDRESS,
|
|
1458
1459
|
});
|
|
1459
1460
|
return res;
|
|
1460
1461
|
}
|
|
1461
1462
|
view.addLiquidity_ = addLiquidity_;
|
|
1462
|
-
async function createPool_(
|
|
1463
|
+
async function createPool_(client, args, typeArguments) {
|
|
1463
1464
|
const tx = new TransactionBlock();
|
|
1464
1465
|
builder.createPool_(tx, args, typeArguments);
|
|
1465
|
-
const res = await
|
|
1466
|
+
const res = await client.devInspectTransactionBlock({
|
|
1466
1467
|
transactionBlock: tx,
|
|
1467
1468
|
sender: ZERO_ADDRESS,
|
|
1468
1469
|
});
|
|
1469
1470
|
return res;
|
|
1470
1471
|
}
|
|
1471
1472
|
view.createPool_ = createPool_;
|
|
1472
|
-
async function removeLiquidity_(
|
|
1473
|
+
async function removeLiquidity_(client, args, typeArguments) {
|
|
1473
1474
|
const tx = new TransactionBlock();
|
|
1474
1475
|
builder.removeLiquidity_(tx, args, typeArguments);
|
|
1475
|
-
const res = await
|
|
1476
|
+
const res = await client.devInspectTransactionBlock({
|
|
1476
1477
|
transactionBlock: tx,
|
|
1477
1478
|
sender: ZERO_ADDRESS,
|
|
1478
1479
|
});
|
|
1479
1480
|
return res;
|
|
1480
1481
|
}
|
|
1481
1482
|
view.removeLiquidity_ = removeLiquidity_;
|
|
1482
|
-
async function swapExactInput_(
|
|
1483
|
+
async function swapExactInput_(client, args, typeArguments) {
|
|
1483
1484
|
const tx = new TransactionBlock();
|
|
1484
1485
|
builder.swapExactInput_(tx, args, typeArguments);
|
|
1485
|
-
const res = await
|
|
1486
|
+
const res = await client.devInspectTransactionBlock({
|
|
1486
1487
|
transactionBlock: tx,
|
|
1487
1488
|
sender: ZERO_ADDRESS,
|
|
1488
1489
|
});
|
|
1489
1490
|
return res;
|
|
1490
1491
|
}
|
|
1491
1492
|
view.swapExactInput_ = swapExactInput_;
|
|
1492
|
-
async function swapExactInputDoublehop_(
|
|
1493
|
+
async function swapExactInputDoublehop_(client, args, typeArguments) {
|
|
1493
1494
|
const tx = new TransactionBlock();
|
|
1494
1495
|
builder.swapExactInputDoublehop_(tx, args, typeArguments);
|
|
1495
|
-
const res = await
|
|
1496
|
+
const res = await client.devInspectTransactionBlock({
|
|
1496
1497
|
transactionBlock: tx,
|
|
1497
1498
|
sender: ZERO_ADDRESS,
|
|
1498
1499
|
});
|
|
1499
1500
|
return res;
|
|
1500
1501
|
}
|
|
1501
1502
|
view.swapExactInputDoublehop_ = swapExactInputDoublehop_;
|
|
1502
|
-
async function swapExactOutput_(
|
|
1503
|
+
async function swapExactOutput_(client, args, typeArguments) {
|
|
1503
1504
|
const tx = new TransactionBlock();
|
|
1504
1505
|
builder.swapExactOutput_(tx, args, typeArguments);
|
|
1505
|
-
const res = await
|
|
1506
|
+
const res = await client.devInspectTransactionBlock({
|
|
1506
1507
|
transactionBlock: tx,
|
|
1507
1508
|
sender: ZERO_ADDRESS,
|
|
1508
1509
|
});
|
|
1509
1510
|
return res;
|
|
1510
1511
|
}
|
|
1511
1512
|
view.swapExactOutput_ = swapExactOutput_;
|
|
1512
|
-
async function swapExactOutputDoublehop_(
|
|
1513
|
+
async function swapExactOutputDoublehop_(client, args, typeArguments) {
|
|
1513
1514
|
const tx = new TransactionBlock();
|
|
1514
1515
|
builder.swapExactOutputDoublehop_(tx, args, typeArguments);
|
|
1515
|
-
const res = await
|
|
1516
|
+
const res = await client.devInspectTransactionBlock({
|
|
1516
1517
|
transactionBlock: tx,
|
|
1517
1518
|
sender: ZERO_ADDRESS,
|
|
1518
1519
|
});
|
|
1519
1520
|
return res;
|
|
1520
1521
|
}
|
|
1521
1522
|
view.swapExactOutputDoublehop_ = swapExactOutputDoublehop_;
|
|
1522
|
-
async function zapIn_(
|
|
1523
|
+
async function zapIn_(client, args, typeArguments) {
|
|
1523
1524
|
const tx = new TransactionBlock();
|
|
1524
1525
|
builder.zapIn_(tx, args, typeArguments);
|
|
1525
|
-
const res = await
|
|
1526
|
+
const res = await client.devInspectTransactionBlock({
|
|
1526
1527
|
transactionBlock: tx,
|
|
1527
1528
|
sender: ZERO_ADDRESS,
|
|
1528
1529
|
});
|