@venusprotocol/isolated-pools 4.2.0-dev.13 → 4.2.0-dev.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -11,6 +11,7 @@ import {
11
11
  PopulatedTransaction,
12
12
  BaseContract,
13
13
  ContractTransaction,
14
+ Overrides,
14
15
  CallOverrides,
15
16
  } from "ethers";
16
17
  import { BytesLike } from "@ethersproject/bytes";
@@ -20,14 +21,89 @@ import type { TypedEventFilter, TypedEvent, TypedListener } from "./common";
20
21
 
21
22
  interface IVTokenInterface extends ethers.utils.Interface {
22
23
  functions: {
24
+ "borrowBalanceCurrent(address)": FunctionFragment;
25
+ "borrowBehalf(address,uint256)": FunctionFragment;
26
+ "exchangeRateCurrent()": FunctionFragment;
27
+ "mintBehalf(address,uint256)": FunctionFragment;
28
+ "redeem(uint256)": FunctionFragment;
29
+ "redeemBehalf(address,uint256)": FunctionFragment;
30
+ "redeemUnderlyingBehalf(address,uint256)": FunctionFragment;
31
+ "repayBorrowBehalf(address,uint256)": FunctionFragment;
32
+ "transferFrom(address,address,uint256)": FunctionFragment;
23
33
  "underlying()": FunctionFragment;
24
34
  };
25
35
 
36
+ encodeFunctionData(
37
+ functionFragment: "borrowBalanceCurrent",
38
+ values: [string]
39
+ ): string;
40
+ encodeFunctionData(
41
+ functionFragment: "borrowBehalf",
42
+ values: [string, BigNumberish]
43
+ ): string;
44
+ encodeFunctionData(
45
+ functionFragment: "exchangeRateCurrent",
46
+ values?: undefined
47
+ ): string;
48
+ encodeFunctionData(
49
+ functionFragment: "mintBehalf",
50
+ values: [string, BigNumberish]
51
+ ): string;
52
+ encodeFunctionData(
53
+ functionFragment: "redeem",
54
+ values: [BigNumberish]
55
+ ): string;
56
+ encodeFunctionData(
57
+ functionFragment: "redeemBehalf",
58
+ values: [string, BigNumberish]
59
+ ): string;
60
+ encodeFunctionData(
61
+ functionFragment: "redeemUnderlyingBehalf",
62
+ values: [string, BigNumberish]
63
+ ): string;
64
+ encodeFunctionData(
65
+ functionFragment: "repayBorrowBehalf",
66
+ values: [string, BigNumberish]
67
+ ): string;
68
+ encodeFunctionData(
69
+ functionFragment: "transferFrom",
70
+ values: [string, string, BigNumberish]
71
+ ): string;
26
72
  encodeFunctionData(
27
73
  functionFragment: "underlying",
28
74
  values?: undefined
29
75
  ): string;
30
76
 
77
+ decodeFunctionResult(
78
+ functionFragment: "borrowBalanceCurrent",
79
+ data: BytesLike
80
+ ): Result;
81
+ decodeFunctionResult(
82
+ functionFragment: "borrowBehalf",
83
+ data: BytesLike
84
+ ): Result;
85
+ decodeFunctionResult(
86
+ functionFragment: "exchangeRateCurrent",
87
+ data: BytesLike
88
+ ): Result;
89
+ decodeFunctionResult(functionFragment: "mintBehalf", data: BytesLike): Result;
90
+ decodeFunctionResult(functionFragment: "redeem", data: BytesLike): Result;
91
+ decodeFunctionResult(
92
+ functionFragment: "redeemBehalf",
93
+ data: BytesLike
94
+ ): Result;
95
+ decodeFunctionResult(
96
+ functionFragment: "redeemUnderlyingBehalf",
97
+ data: BytesLike
98
+ ): Result;
99
+ decodeFunctionResult(
100
+ functionFragment: "repayBorrowBehalf",
101
+ data: BytesLike
102
+ ): Result;
103
+ decodeFunctionResult(
104
+ functionFragment: "transferFrom",
105
+ data: BytesLike
106
+ ): Result;
31
107
  decodeFunctionResult(functionFragment: "underlying", data: BytesLike): Result;
32
108
 
33
109
  events: {};
@@ -77,22 +153,283 @@ export class IVToken extends BaseContract {
77
153
  interface: IVTokenInterface;
78
154
 
79
155
  functions: {
80
- underlying(overrides?: CallOverrides): Promise<[string]>;
156
+ borrowBalanceCurrent(
157
+ account: string,
158
+ overrides?: Overrides & { from?: string | Promise<string> }
159
+ ): Promise<ContractTransaction>;
160
+
161
+ borrowBehalf(
162
+ borrower: string,
163
+ borrowAmount: BigNumberish,
164
+ overrides?: Overrides & { from?: string | Promise<string> }
165
+ ): Promise<ContractTransaction>;
166
+
167
+ exchangeRateCurrent(
168
+ overrides?: Overrides & { from?: string | Promise<string> }
169
+ ): Promise<ContractTransaction>;
170
+
171
+ mintBehalf(
172
+ receiver: string,
173
+ mintAmount: BigNumberish,
174
+ overrides?: Overrides & { from?: string | Promise<string> }
175
+ ): Promise<ContractTransaction>;
176
+
177
+ redeem(
178
+ redeemTokens: BigNumberish,
179
+ overrides?: Overrides & { from?: string | Promise<string> }
180
+ ): Promise<ContractTransaction>;
181
+
182
+ redeemBehalf(
183
+ redeemer: string,
184
+ redeemTokens: BigNumberish,
185
+ overrides?: Overrides & { from?: string | Promise<string> }
186
+ ): Promise<ContractTransaction>;
187
+
188
+ redeemUnderlyingBehalf(
189
+ redeemer: string,
190
+ redeemAmount: BigNumberish,
191
+ overrides?: Overrides & { from?: string | Promise<string> }
192
+ ): Promise<ContractTransaction>;
193
+
194
+ repayBorrowBehalf(
195
+ borrower: string,
196
+ repayAmount: BigNumberish,
197
+ overrides?: Overrides & { from?: string | Promise<string> }
198
+ ): Promise<ContractTransaction>;
199
+
200
+ transferFrom(
201
+ from: string,
202
+ to: string,
203
+ amount: BigNumberish,
204
+ overrides?: Overrides & { from?: string | Promise<string> }
205
+ ): Promise<ContractTransaction>;
206
+
207
+ underlying(
208
+ overrides?: Overrides & { from?: string | Promise<string> }
209
+ ): Promise<ContractTransaction>;
81
210
  };
82
211
 
83
- underlying(overrides?: CallOverrides): Promise<string>;
212
+ borrowBalanceCurrent(
213
+ account: string,
214
+ overrides?: Overrides & { from?: string | Promise<string> }
215
+ ): Promise<ContractTransaction>;
216
+
217
+ borrowBehalf(
218
+ borrower: string,
219
+ borrowAmount: BigNumberish,
220
+ overrides?: Overrides & { from?: string | Promise<string> }
221
+ ): Promise<ContractTransaction>;
222
+
223
+ exchangeRateCurrent(
224
+ overrides?: Overrides & { from?: string | Promise<string> }
225
+ ): Promise<ContractTransaction>;
226
+
227
+ mintBehalf(
228
+ receiver: string,
229
+ mintAmount: BigNumberish,
230
+ overrides?: Overrides & { from?: string | Promise<string> }
231
+ ): Promise<ContractTransaction>;
232
+
233
+ redeem(
234
+ redeemTokens: BigNumberish,
235
+ overrides?: Overrides & { from?: string | Promise<string> }
236
+ ): Promise<ContractTransaction>;
237
+
238
+ redeemBehalf(
239
+ redeemer: string,
240
+ redeemTokens: BigNumberish,
241
+ overrides?: Overrides & { from?: string | Promise<string> }
242
+ ): Promise<ContractTransaction>;
243
+
244
+ redeemUnderlyingBehalf(
245
+ redeemer: string,
246
+ redeemAmount: BigNumberish,
247
+ overrides?: Overrides & { from?: string | Promise<string> }
248
+ ): Promise<ContractTransaction>;
249
+
250
+ repayBorrowBehalf(
251
+ borrower: string,
252
+ repayAmount: BigNumberish,
253
+ overrides?: Overrides & { from?: string | Promise<string> }
254
+ ): Promise<ContractTransaction>;
255
+
256
+ transferFrom(
257
+ from: string,
258
+ to: string,
259
+ amount: BigNumberish,
260
+ overrides?: Overrides & { from?: string | Promise<string> }
261
+ ): Promise<ContractTransaction>;
262
+
263
+ underlying(
264
+ overrides?: Overrides & { from?: string | Promise<string> }
265
+ ): Promise<ContractTransaction>;
84
266
 
85
267
  callStatic: {
268
+ borrowBalanceCurrent(
269
+ account: string,
270
+ overrides?: CallOverrides
271
+ ): Promise<BigNumber>;
272
+
273
+ borrowBehalf(
274
+ borrower: string,
275
+ borrowAmount: BigNumberish,
276
+ overrides?: CallOverrides
277
+ ): Promise<BigNumber>;
278
+
279
+ exchangeRateCurrent(overrides?: CallOverrides): Promise<BigNumber>;
280
+
281
+ mintBehalf(
282
+ receiver: string,
283
+ mintAmount: BigNumberish,
284
+ overrides?: CallOverrides
285
+ ): Promise<BigNumber>;
286
+
287
+ redeem(
288
+ redeemTokens: BigNumberish,
289
+ overrides?: CallOverrides
290
+ ): Promise<BigNumber>;
291
+
292
+ redeemBehalf(
293
+ redeemer: string,
294
+ redeemTokens: BigNumberish,
295
+ overrides?: CallOverrides
296
+ ): Promise<BigNumber>;
297
+
298
+ redeemUnderlyingBehalf(
299
+ redeemer: string,
300
+ redeemAmount: BigNumberish,
301
+ overrides?: CallOverrides
302
+ ): Promise<BigNumber>;
303
+
304
+ repayBorrowBehalf(
305
+ borrower: string,
306
+ repayAmount: BigNumberish,
307
+ overrides?: CallOverrides
308
+ ): Promise<BigNumber>;
309
+
310
+ transferFrom(
311
+ from: string,
312
+ to: string,
313
+ amount: BigNumberish,
314
+ overrides?: CallOverrides
315
+ ): Promise<boolean>;
316
+
86
317
  underlying(overrides?: CallOverrides): Promise<string>;
87
318
  };
88
319
 
89
320
  filters: {};
90
321
 
91
322
  estimateGas: {
92
- underlying(overrides?: CallOverrides): Promise<BigNumber>;
323
+ borrowBalanceCurrent(
324
+ account: string,
325
+ overrides?: Overrides & { from?: string | Promise<string> }
326
+ ): Promise<BigNumber>;
327
+
328
+ borrowBehalf(
329
+ borrower: string,
330
+ borrowAmount: BigNumberish,
331
+ overrides?: Overrides & { from?: string | Promise<string> }
332
+ ): Promise<BigNumber>;
333
+
334
+ exchangeRateCurrent(
335
+ overrides?: Overrides & { from?: string | Promise<string> }
336
+ ): Promise<BigNumber>;
337
+
338
+ mintBehalf(
339
+ receiver: string,
340
+ mintAmount: BigNumberish,
341
+ overrides?: Overrides & { from?: string | Promise<string> }
342
+ ): Promise<BigNumber>;
343
+
344
+ redeem(
345
+ redeemTokens: BigNumberish,
346
+ overrides?: Overrides & { from?: string | Promise<string> }
347
+ ): Promise<BigNumber>;
348
+
349
+ redeemBehalf(
350
+ redeemer: string,
351
+ redeemTokens: BigNumberish,
352
+ overrides?: Overrides & { from?: string | Promise<string> }
353
+ ): Promise<BigNumber>;
354
+
355
+ redeemUnderlyingBehalf(
356
+ redeemer: string,
357
+ redeemAmount: BigNumberish,
358
+ overrides?: Overrides & { from?: string | Promise<string> }
359
+ ): Promise<BigNumber>;
360
+
361
+ repayBorrowBehalf(
362
+ borrower: string,
363
+ repayAmount: BigNumberish,
364
+ overrides?: Overrides & { from?: string | Promise<string> }
365
+ ): Promise<BigNumber>;
366
+
367
+ transferFrom(
368
+ from: string,
369
+ to: string,
370
+ amount: BigNumberish,
371
+ overrides?: Overrides & { from?: string | Promise<string> }
372
+ ): Promise<BigNumber>;
373
+
374
+ underlying(
375
+ overrides?: Overrides & { from?: string | Promise<string> }
376
+ ): Promise<BigNumber>;
93
377
  };
94
378
 
95
379
  populateTransaction: {
96
- underlying(overrides?: CallOverrides): Promise<PopulatedTransaction>;
380
+ borrowBalanceCurrent(
381
+ account: string,
382
+ overrides?: Overrides & { from?: string | Promise<string> }
383
+ ): Promise<PopulatedTransaction>;
384
+
385
+ borrowBehalf(
386
+ borrower: string,
387
+ borrowAmount: BigNumberish,
388
+ overrides?: Overrides & { from?: string | Promise<string> }
389
+ ): Promise<PopulatedTransaction>;
390
+
391
+ exchangeRateCurrent(
392
+ overrides?: Overrides & { from?: string | Promise<string> }
393
+ ): Promise<PopulatedTransaction>;
394
+
395
+ mintBehalf(
396
+ receiver: string,
397
+ mintAmount: BigNumberish,
398
+ overrides?: Overrides & { from?: string | Promise<string> }
399
+ ): Promise<PopulatedTransaction>;
400
+
401
+ redeem(
402
+ redeemTokens: BigNumberish,
403
+ overrides?: Overrides & { from?: string | Promise<string> }
404
+ ): Promise<PopulatedTransaction>;
405
+
406
+ redeemBehalf(
407
+ redeemer: string,
408
+ redeemTokens: BigNumberish,
409
+ overrides?: Overrides & { from?: string | Promise<string> }
410
+ ): Promise<PopulatedTransaction>;
411
+
412
+ redeemUnderlyingBehalf(
413
+ redeemer: string,
414
+ redeemAmount: BigNumberish,
415
+ overrides?: Overrides & { from?: string | Promise<string> }
416
+ ): Promise<PopulatedTransaction>;
417
+
418
+ repayBorrowBehalf(
419
+ borrower: string,
420
+ repayAmount: BigNumberish,
421
+ overrides?: Overrides & { from?: string | Promise<string> }
422
+ ): Promise<PopulatedTransaction>;
423
+
424
+ transferFrom(
425
+ from: string,
426
+ to: string,
427
+ amount: BigNumberish,
428
+ overrides?: Overrides & { from?: string | Promise<string> }
429
+ ): Promise<PopulatedTransaction>;
430
+
431
+ underlying(
432
+ overrides?: Overrides & { from?: string | Promise<string> }
433
+ ): Promise<PopulatedTransaction>;
97
434
  };
98
435
  }
@@ -7,6 +7,206 @@ import { Provider } from "@ethersproject/providers";
7
7
  import type { IVToken, IVTokenInterface } from "../IVToken";
8
8
 
9
9
  const _abi = [
10
+ {
11
+ inputs: [
12
+ {
13
+ internalType: "address",
14
+ name: "account",
15
+ type: "address",
16
+ },
17
+ ],
18
+ name: "borrowBalanceCurrent",
19
+ outputs: [
20
+ {
21
+ internalType: "uint256",
22
+ name: "",
23
+ type: "uint256",
24
+ },
25
+ ],
26
+ stateMutability: "nonpayable",
27
+ type: "function",
28
+ },
29
+ {
30
+ inputs: [
31
+ {
32
+ internalType: "address",
33
+ name: "borrower",
34
+ type: "address",
35
+ },
36
+ {
37
+ internalType: "uint256",
38
+ name: "borrowAmount",
39
+ type: "uint256",
40
+ },
41
+ ],
42
+ name: "borrowBehalf",
43
+ outputs: [
44
+ {
45
+ internalType: "uint256",
46
+ name: "",
47
+ type: "uint256",
48
+ },
49
+ ],
50
+ stateMutability: "nonpayable",
51
+ type: "function",
52
+ },
53
+ {
54
+ inputs: [],
55
+ name: "exchangeRateCurrent",
56
+ outputs: [
57
+ {
58
+ internalType: "uint256",
59
+ name: "",
60
+ type: "uint256",
61
+ },
62
+ ],
63
+ stateMutability: "nonpayable",
64
+ type: "function",
65
+ },
66
+ {
67
+ inputs: [
68
+ {
69
+ internalType: "address",
70
+ name: "receiver",
71
+ type: "address",
72
+ },
73
+ {
74
+ internalType: "uint256",
75
+ name: "mintAmount",
76
+ type: "uint256",
77
+ },
78
+ ],
79
+ name: "mintBehalf",
80
+ outputs: [
81
+ {
82
+ internalType: "uint256",
83
+ name: "",
84
+ type: "uint256",
85
+ },
86
+ ],
87
+ stateMutability: "nonpayable",
88
+ type: "function",
89
+ },
90
+ {
91
+ inputs: [
92
+ {
93
+ internalType: "uint256",
94
+ name: "redeemTokens",
95
+ type: "uint256",
96
+ },
97
+ ],
98
+ name: "redeem",
99
+ outputs: [
100
+ {
101
+ internalType: "uint256",
102
+ name: "",
103
+ type: "uint256",
104
+ },
105
+ ],
106
+ stateMutability: "nonpayable",
107
+ type: "function",
108
+ },
109
+ {
110
+ inputs: [
111
+ {
112
+ internalType: "address",
113
+ name: "redeemer",
114
+ type: "address",
115
+ },
116
+ {
117
+ internalType: "uint256",
118
+ name: "redeemTokens",
119
+ type: "uint256",
120
+ },
121
+ ],
122
+ name: "redeemBehalf",
123
+ outputs: [
124
+ {
125
+ internalType: "uint256",
126
+ name: "",
127
+ type: "uint256",
128
+ },
129
+ ],
130
+ stateMutability: "nonpayable",
131
+ type: "function",
132
+ },
133
+ {
134
+ inputs: [
135
+ {
136
+ internalType: "address",
137
+ name: "redeemer",
138
+ type: "address",
139
+ },
140
+ {
141
+ internalType: "uint256",
142
+ name: "redeemAmount",
143
+ type: "uint256",
144
+ },
145
+ ],
146
+ name: "redeemUnderlyingBehalf",
147
+ outputs: [
148
+ {
149
+ internalType: "uint256",
150
+ name: "",
151
+ type: "uint256",
152
+ },
153
+ ],
154
+ stateMutability: "nonpayable",
155
+ type: "function",
156
+ },
157
+ {
158
+ inputs: [
159
+ {
160
+ internalType: "address",
161
+ name: "borrower",
162
+ type: "address",
163
+ },
164
+ {
165
+ internalType: "uint256",
166
+ name: "repayAmount",
167
+ type: "uint256",
168
+ },
169
+ ],
170
+ name: "repayBorrowBehalf",
171
+ outputs: [
172
+ {
173
+ internalType: "uint256",
174
+ name: "",
175
+ type: "uint256",
176
+ },
177
+ ],
178
+ stateMutability: "nonpayable",
179
+ type: "function",
180
+ },
181
+ {
182
+ inputs: [
183
+ {
184
+ internalType: "address",
185
+ name: "from",
186
+ type: "address",
187
+ },
188
+ {
189
+ internalType: "address",
190
+ name: "to",
191
+ type: "address",
192
+ },
193
+ {
194
+ internalType: "uint256",
195
+ name: "amount",
196
+ type: "uint256",
197
+ },
198
+ ],
199
+ name: "transferFrom",
200
+ outputs: [
201
+ {
202
+ internalType: "bool",
203
+ name: "",
204
+ type: "bool",
205
+ },
206
+ ],
207
+ stateMutability: "nonpayable",
208
+ type: "function",
209
+ },
10
210
  {
11
211
  inputs: [],
12
212
  name: "underlying",
@@ -17,7 +217,7 @@ const _abi = [
17
217
  type: "address",
18
218
  },
19
219
  ],
20
- stateMutability: "view",
220
+ stateMutability: "nonpayable",
21
221
  type: "function",
22
222
  },
23
223
  ];