@web3dotorg/evm-slc-core-sdk 0.3.2
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/common.ts +131 -0
- package/constants.ts +34 -0
- package/contracts/governance/ExecutorsRegistry.ts +1249 -0
- package/contracts/governance/Governance.ts +1740 -0
- package/contracts/governance/NeutralsRegistry.ts +1393 -0
- package/contracts/governance/ParameterRegistry.ts +832 -0
- package/contracts/governance/index.ts +7 -0
- package/contracts/index.ts +15 -0
- package/contracts/interfaces/IExecutorsRegistry.ts +601 -0
- package/contracts/interfaces/IGovernance.ts +215 -0
- package/contracts/interfaces/INeutralsRegistry.ts +624 -0
- package/contracts/interfaces/IQParameters.ts +109 -0
- package/contracts/interfaces/ISLCCore.ts +289 -0
- package/contracts/interfaces/ISLCCoreFactory.ts +217 -0
- package/contracts/interfaces/IWrappedToken.ts +272 -0
- package/contracts/interfaces/index.ts +10 -0
- package/contracts/libs/Errors.ts +71 -0
- package/contracts/libs/NeutralsSelection.ts +71 -0
- package/contracts/libs/index.ts +5 -0
- package/contracts/mocks/MockGovernance.ts +389 -0
- package/contracts/mocks/MockNeutralsRegistry.ts +791 -0
- package/contracts/mocks/SimpleContract.ts +110 -0
- package/contracts/mocks/WrappedToken.ts +334 -0
- package/contracts/mocks/index.ts +7 -0
- package/contracts/slc-core/SLCCore.ts +397 -0
- package/contracts/slc-core/SLCCoreFactory.ts +559 -0
- package/contracts/slc-core/index.ts +5 -0
- package/contracts/token/Token.ts +399 -0
- package/contracts/token/index.ts +4 -0
- package/factories/contracts/governance/ExecutorsRegistry__factory.ts +1240 -0
- package/factories/contracts/governance/Governance__factory.ts +2328 -0
- package/factories/contracts/governance/NeutralsRegistry__factory.ts +1491 -0
- package/factories/contracts/governance/ParameterRegistry__factory.ts +834 -0
- package/factories/contracts/governance/index.ts +7 -0
- package/factories/contracts/index.ts +9 -0
- package/factories/contracts/interfaces/IExecutorsRegistry__factory.ts +428 -0
- package/factories/contracts/interfaces/IGovernance__factory.ts +153 -0
- package/factories/contracts/interfaces/INeutralsRegistry__factory.ts +527 -0
- package/factories/contracts/interfaces/IQParameters__factory.ts +101 -0
- package/factories/contracts/interfaces/ISLCCoreFactory__factory.ts +197 -0
- package/factories/contracts/interfaces/ISLCCore__factory.ts +227 -0
- package/factories/contracts/interfaces/IWrappedToken__factory.ts +221 -0
- package/factories/contracts/interfaces/index.ts +10 -0
- package/factories/contracts/libs/Errors__factory.ts +205 -0
- package/factories/contracts/libs/NeutralsSelection__factory.ts +103 -0
- package/factories/contracts/libs/index.ts +5 -0
- package/factories/contracts/mocks/MockGovernance__factory.ts +353 -0
- package/factories/contracts/mocks/MockNeutralsRegistry__factory.ts +730 -0
- package/factories/contracts/mocks/SimpleContract__factory.ts +110 -0
- package/factories/contracts/mocks/WrappedToken__factory.ts +433 -0
- package/factories/contracts/mocks/index.ts +7 -0
- package/factories/contracts/slc-core/SLCCoreFactory__factory.ts +568 -0
- package/factories/contracts/slc-core/SLCCore__factory.ts +373 -0
- package/factories/contracts/slc-core/index.ts +5 -0
- package/factories/contracts/token/Token__factory.ts +505 -0
- package/factories/contracts/token/index.ts +4 -0
- package/index.ts +38 -0
- package/package.json +25 -0
@@ -0,0 +1,730 @@
|
|
1
|
+
/* Autogenerated file. Do not edit manually. */
|
2
|
+
/* tslint:disable */
|
3
|
+
/* eslint-disable */
|
4
|
+
import {
|
5
|
+
Contract,
|
6
|
+
ContractFactory,
|
7
|
+
ContractTransactionResponse,
|
8
|
+
Interface,
|
9
|
+
} from "ethers";
|
10
|
+
import type { Signer, ContractDeployTransaction, ContractRunner } from "ethers";
|
11
|
+
import type { NonPayableOverrides } from "../../../common";
|
12
|
+
import type {
|
13
|
+
MockNeutralsRegistry,
|
14
|
+
MockNeutralsRegistryInterface,
|
15
|
+
} from "../../../contracts/mocks/MockNeutralsRegistry";
|
16
|
+
|
17
|
+
const _abi = [
|
18
|
+
{
|
19
|
+
inputs: [
|
20
|
+
{
|
21
|
+
internalType: "address",
|
22
|
+
name: "delegator",
|
23
|
+
type: "address",
|
24
|
+
},
|
25
|
+
{
|
26
|
+
internalType: "address",
|
27
|
+
name: "neutral",
|
28
|
+
type: "address",
|
29
|
+
},
|
30
|
+
{
|
31
|
+
internalType: "uint256",
|
32
|
+
name: "requested",
|
33
|
+
type: "uint256",
|
34
|
+
},
|
35
|
+
{
|
36
|
+
internalType: "uint256",
|
37
|
+
name: "availible",
|
38
|
+
type: "uint256",
|
39
|
+
},
|
40
|
+
],
|
41
|
+
name: "InsufficientDelegationAmount",
|
42
|
+
type: "error",
|
43
|
+
},
|
44
|
+
{
|
45
|
+
inputs: [
|
46
|
+
{
|
47
|
+
internalType: "uint256",
|
48
|
+
name: "amount",
|
49
|
+
type: "uint256",
|
50
|
+
},
|
51
|
+
],
|
52
|
+
name: "InvalidDelegationAmount",
|
53
|
+
type: "error",
|
54
|
+
},
|
55
|
+
{
|
56
|
+
inputs: [
|
57
|
+
{
|
58
|
+
internalType: "uint256",
|
59
|
+
name: "requestedDelegation",
|
60
|
+
type: "uint256",
|
61
|
+
},
|
62
|
+
{
|
63
|
+
internalType: "uint256",
|
64
|
+
name: "currentDelegatedStake",
|
65
|
+
type: "uint256",
|
66
|
+
},
|
67
|
+
{
|
68
|
+
internalType: "uint256",
|
69
|
+
name: "maxPossibleDelegatedStake",
|
70
|
+
type: "uint256",
|
71
|
+
},
|
72
|
+
],
|
73
|
+
name: "MaxDelegationAmplificationConstraintViolated",
|
74
|
+
type: "error",
|
75
|
+
},
|
76
|
+
{
|
77
|
+
inputs: [
|
78
|
+
{
|
79
|
+
internalType: "address",
|
80
|
+
name: "neutral",
|
81
|
+
type: "address",
|
82
|
+
},
|
83
|
+
],
|
84
|
+
name: "NeutralAlreadyPaused",
|
85
|
+
type: "error",
|
86
|
+
},
|
87
|
+
{
|
88
|
+
inputs: [
|
89
|
+
{
|
90
|
+
internalType: "address",
|
91
|
+
name: "subject",
|
92
|
+
type: "address",
|
93
|
+
},
|
94
|
+
],
|
95
|
+
name: "NeutralCannotDelegateToHimself",
|
96
|
+
type: "error",
|
97
|
+
},
|
98
|
+
{
|
99
|
+
inputs: [
|
100
|
+
{
|
101
|
+
internalType: "address",
|
102
|
+
name: "neutral",
|
103
|
+
type: "address",
|
104
|
+
},
|
105
|
+
],
|
106
|
+
name: "NeutralHasNoStake",
|
107
|
+
type: "error",
|
108
|
+
},
|
109
|
+
{
|
110
|
+
inputs: [
|
111
|
+
{
|
112
|
+
internalType: "address",
|
113
|
+
name: "neutral",
|
114
|
+
type: "address",
|
115
|
+
},
|
116
|
+
],
|
117
|
+
name: "NeutralNotPaused",
|
118
|
+
type: "error",
|
119
|
+
},
|
120
|
+
{
|
121
|
+
inputs: [
|
122
|
+
{
|
123
|
+
internalType: "address",
|
124
|
+
name: "subject",
|
125
|
+
type: "address",
|
126
|
+
},
|
127
|
+
],
|
128
|
+
name: "NoWithdrawalAnnouncement",
|
129
|
+
type: "error",
|
130
|
+
},
|
131
|
+
{
|
132
|
+
inputs: [
|
133
|
+
{
|
134
|
+
internalType: "uint256",
|
135
|
+
name: "providedNumber",
|
136
|
+
type: "uint256",
|
137
|
+
},
|
138
|
+
{
|
139
|
+
internalType: "uint256",
|
140
|
+
name: "activeNeutralsCount",
|
141
|
+
type: "uint256",
|
142
|
+
},
|
143
|
+
],
|
144
|
+
name: "SelectedNeutralsNumberOutOfRange",
|
145
|
+
type: "error",
|
146
|
+
},
|
147
|
+
{
|
148
|
+
inputs: [
|
149
|
+
{
|
150
|
+
internalType: "address",
|
151
|
+
name: "subject",
|
152
|
+
type: "address",
|
153
|
+
},
|
154
|
+
],
|
155
|
+
name: "WithdrawalAlreadyAnnounced",
|
156
|
+
type: "error",
|
157
|
+
},
|
158
|
+
{
|
159
|
+
inputs: [
|
160
|
+
{
|
161
|
+
internalType: "address",
|
162
|
+
name: "subject",
|
163
|
+
type: "address",
|
164
|
+
},
|
165
|
+
{
|
166
|
+
internalType: "uint256",
|
167
|
+
name: "availableAt",
|
168
|
+
type: "uint256",
|
169
|
+
},
|
170
|
+
],
|
171
|
+
name: "WithdrawalNotReady",
|
172
|
+
type: "error",
|
173
|
+
},
|
174
|
+
{
|
175
|
+
anonymous: false,
|
176
|
+
inputs: [
|
177
|
+
{
|
178
|
+
indexed: false,
|
179
|
+
internalType: "address",
|
180
|
+
name: "delegator",
|
181
|
+
type: "address",
|
182
|
+
},
|
183
|
+
{
|
184
|
+
indexed: false,
|
185
|
+
internalType: "address",
|
186
|
+
name: "neutral",
|
187
|
+
type: "address",
|
188
|
+
},
|
189
|
+
{
|
190
|
+
indexed: false,
|
191
|
+
internalType: "uint256",
|
192
|
+
name: "amount",
|
193
|
+
type: "uint256",
|
194
|
+
},
|
195
|
+
],
|
196
|
+
name: "DelegationWithdrawn",
|
197
|
+
type: "event",
|
198
|
+
},
|
199
|
+
{
|
200
|
+
anonymous: false,
|
201
|
+
inputs: [
|
202
|
+
{
|
203
|
+
indexed: true,
|
204
|
+
internalType: "address",
|
205
|
+
name: "neutral",
|
206
|
+
type: "address",
|
207
|
+
},
|
208
|
+
{
|
209
|
+
indexed: false,
|
210
|
+
internalType: "uint256",
|
211
|
+
name: "stake",
|
212
|
+
type: "uint256",
|
213
|
+
},
|
214
|
+
],
|
215
|
+
name: "NeutralActivated",
|
216
|
+
type: "event",
|
217
|
+
},
|
218
|
+
{
|
219
|
+
anonymous: false,
|
220
|
+
inputs: [
|
221
|
+
{
|
222
|
+
indexed: true,
|
223
|
+
internalType: "address",
|
224
|
+
name: "neutral",
|
225
|
+
type: "address",
|
226
|
+
},
|
227
|
+
],
|
228
|
+
name: "NeutralMovedToStandby",
|
229
|
+
type: "event",
|
230
|
+
},
|
231
|
+
{
|
232
|
+
anonymous: false,
|
233
|
+
inputs: [
|
234
|
+
{
|
235
|
+
indexed: true,
|
236
|
+
internalType: "address",
|
237
|
+
name: "neutral",
|
238
|
+
type: "address",
|
239
|
+
},
|
240
|
+
],
|
241
|
+
name: "NeutralPaused",
|
242
|
+
type: "event",
|
243
|
+
},
|
244
|
+
{
|
245
|
+
anonymous: false,
|
246
|
+
inputs: [
|
247
|
+
{
|
248
|
+
indexed: true,
|
249
|
+
internalType: "address",
|
250
|
+
name: "neutral",
|
251
|
+
type: "address",
|
252
|
+
},
|
253
|
+
{
|
254
|
+
indexed: false,
|
255
|
+
internalType: "uint256",
|
256
|
+
name: "amount",
|
257
|
+
type: "uint256",
|
258
|
+
},
|
259
|
+
{
|
260
|
+
indexed: false,
|
261
|
+
internalType: "address",
|
262
|
+
name: "recipient",
|
263
|
+
type: "address",
|
264
|
+
},
|
265
|
+
],
|
266
|
+
name: "NeutralSlashed",
|
267
|
+
type: "event",
|
268
|
+
},
|
269
|
+
{
|
270
|
+
anonymous: false,
|
271
|
+
inputs: [
|
272
|
+
{
|
273
|
+
indexed: true,
|
274
|
+
internalType: "address",
|
275
|
+
name: "neutral",
|
276
|
+
type: "address",
|
277
|
+
},
|
278
|
+
{
|
279
|
+
indexed: false,
|
280
|
+
internalType: "uint256",
|
281
|
+
name: "amount",
|
282
|
+
type: "uint256",
|
283
|
+
},
|
284
|
+
{
|
285
|
+
indexed: false,
|
286
|
+
internalType: "uint256",
|
287
|
+
name: "totalStake",
|
288
|
+
type: "uint256",
|
289
|
+
},
|
290
|
+
],
|
291
|
+
name: "NeutralStaked",
|
292
|
+
type: "event",
|
293
|
+
},
|
294
|
+
{
|
295
|
+
anonymous: false,
|
296
|
+
inputs: [
|
297
|
+
{
|
298
|
+
indexed: true,
|
299
|
+
internalType: "address",
|
300
|
+
name: "neutral",
|
301
|
+
type: "address",
|
302
|
+
},
|
303
|
+
],
|
304
|
+
name: "NeutralUnpaused",
|
305
|
+
type: "event",
|
306
|
+
},
|
307
|
+
{
|
308
|
+
anonymous: false,
|
309
|
+
inputs: [
|
310
|
+
{
|
311
|
+
indexed: true,
|
312
|
+
internalType: "address",
|
313
|
+
name: "neutral",
|
314
|
+
type: "address",
|
315
|
+
},
|
316
|
+
{
|
317
|
+
indexed: false,
|
318
|
+
internalType: "uint256",
|
319
|
+
name: "amount",
|
320
|
+
type: "uint256",
|
321
|
+
},
|
322
|
+
{
|
323
|
+
indexed: false,
|
324
|
+
internalType: "uint256",
|
325
|
+
name: "remainingStake",
|
326
|
+
type: "uint256",
|
327
|
+
},
|
328
|
+
],
|
329
|
+
name: "NeutralUnstaked",
|
330
|
+
type: "event",
|
331
|
+
},
|
332
|
+
{
|
333
|
+
anonymous: false,
|
334
|
+
inputs: [
|
335
|
+
{
|
336
|
+
indexed: true,
|
337
|
+
internalType: "address",
|
338
|
+
name: "neutral",
|
339
|
+
type: "address",
|
340
|
+
},
|
341
|
+
{
|
342
|
+
indexed: false,
|
343
|
+
internalType: "uint256",
|
344
|
+
name: "amount",
|
345
|
+
type: "uint256",
|
346
|
+
},
|
347
|
+
],
|
348
|
+
name: "RewardsClaimed",
|
349
|
+
type: "event",
|
350
|
+
},
|
351
|
+
{
|
352
|
+
anonymous: false,
|
353
|
+
inputs: [
|
354
|
+
{
|
355
|
+
indexed: false,
|
356
|
+
internalType: "address[]",
|
357
|
+
name: "selectedNeutrals",
|
358
|
+
type: "address[]",
|
359
|
+
},
|
360
|
+
{
|
361
|
+
indexed: false,
|
362
|
+
internalType: "uint256",
|
363
|
+
name: "totalAmount",
|
364
|
+
type: "uint256",
|
365
|
+
},
|
366
|
+
],
|
367
|
+
name: "RewardsDistributed",
|
368
|
+
type: "event",
|
369
|
+
},
|
370
|
+
{
|
371
|
+
anonymous: false,
|
372
|
+
inputs: [
|
373
|
+
{
|
374
|
+
indexed: true,
|
375
|
+
internalType: "address",
|
376
|
+
name: "neutral",
|
377
|
+
type: "address",
|
378
|
+
},
|
379
|
+
{
|
380
|
+
indexed: false,
|
381
|
+
internalType: "uint256",
|
382
|
+
name: "amount",
|
383
|
+
type: "uint256",
|
384
|
+
},
|
385
|
+
{
|
386
|
+
indexed: false,
|
387
|
+
internalType: "uint256",
|
388
|
+
name: "availableAt",
|
389
|
+
type: "uint256",
|
390
|
+
},
|
391
|
+
],
|
392
|
+
name: "WithdrawalAnnounced",
|
393
|
+
type: "event",
|
394
|
+
},
|
395
|
+
{
|
396
|
+
anonymous: false,
|
397
|
+
inputs: [
|
398
|
+
{
|
399
|
+
indexed: true,
|
400
|
+
internalType: "address",
|
401
|
+
name: "neutral",
|
402
|
+
type: "address",
|
403
|
+
},
|
404
|
+
{
|
405
|
+
indexed: false,
|
406
|
+
internalType: "uint256",
|
407
|
+
name: "amount",
|
408
|
+
type: "uint256",
|
409
|
+
},
|
410
|
+
],
|
411
|
+
name: "WithdrawalCancelled",
|
412
|
+
type: "event",
|
413
|
+
},
|
414
|
+
{
|
415
|
+
inputs: [
|
416
|
+
{
|
417
|
+
internalType: "address",
|
418
|
+
name: "neutral_",
|
419
|
+
type: "address",
|
420
|
+
},
|
421
|
+
{
|
422
|
+
internalType: "string",
|
423
|
+
name: "externalLink_",
|
424
|
+
type: "string",
|
425
|
+
},
|
426
|
+
],
|
427
|
+
name: "addNeutral",
|
428
|
+
outputs: [],
|
429
|
+
stateMutability: "nonpayable",
|
430
|
+
type: "function",
|
431
|
+
},
|
432
|
+
{
|
433
|
+
inputs: [
|
434
|
+
{
|
435
|
+
internalType: "address[]",
|
436
|
+
name: "neutrals_",
|
437
|
+
type: "address[]",
|
438
|
+
},
|
439
|
+
],
|
440
|
+
name: "addNeutrals",
|
441
|
+
outputs: [],
|
442
|
+
stateMutability: "nonpayable",
|
443
|
+
type: "function",
|
444
|
+
},
|
445
|
+
{
|
446
|
+
inputs: [],
|
447
|
+
name: "clearNeutrals",
|
448
|
+
outputs: [],
|
449
|
+
stateMutability: "nonpayable",
|
450
|
+
type: "function",
|
451
|
+
},
|
452
|
+
{
|
453
|
+
inputs: [
|
454
|
+
{
|
455
|
+
internalType: "address[]",
|
456
|
+
name: "selectedNeutrals_",
|
457
|
+
type: "address[]",
|
458
|
+
},
|
459
|
+
{
|
460
|
+
internalType: "uint256",
|
461
|
+
name: "amount_",
|
462
|
+
type: "uint256",
|
463
|
+
},
|
464
|
+
],
|
465
|
+
name: "distributeRewards",
|
466
|
+
outputs: [],
|
467
|
+
stateMutability: "nonpayable",
|
468
|
+
type: "function",
|
469
|
+
},
|
470
|
+
{
|
471
|
+
inputs: [],
|
472
|
+
name: "getActiveNeutrals",
|
473
|
+
outputs: [
|
474
|
+
{
|
475
|
+
internalType: "address[]",
|
476
|
+
name: "",
|
477
|
+
type: "address[]",
|
478
|
+
},
|
479
|
+
],
|
480
|
+
stateMutability: "view",
|
481
|
+
type: "function",
|
482
|
+
},
|
483
|
+
{
|
484
|
+
inputs: [
|
485
|
+
{
|
486
|
+
internalType: "address",
|
487
|
+
name: "candidate_",
|
488
|
+
type: "address",
|
489
|
+
},
|
490
|
+
],
|
491
|
+
name: "getNeutralInfo",
|
492
|
+
outputs: [
|
493
|
+
{
|
494
|
+
components: [
|
495
|
+
{
|
496
|
+
internalType: "uint256",
|
497
|
+
name: "selfStake",
|
498
|
+
type: "uint256",
|
499
|
+
},
|
500
|
+
{
|
501
|
+
internalType: "uint256",
|
502
|
+
name: "weight",
|
503
|
+
type: "uint256",
|
504
|
+
},
|
505
|
+
{
|
506
|
+
internalType: "uint256",
|
507
|
+
name: "delegatedStake",
|
508
|
+
type: "uint256",
|
509
|
+
},
|
510
|
+
{
|
511
|
+
internalType: "uint256",
|
512
|
+
name: "rewards",
|
513
|
+
type: "uint256",
|
514
|
+
},
|
515
|
+
{
|
516
|
+
internalType: "uint256",
|
517
|
+
name: "delegationShare",
|
518
|
+
type: "uint256",
|
519
|
+
},
|
520
|
+
{
|
521
|
+
internalType: "bool",
|
522
|
+
name: "isActive",
|
523
|
+
type: "bool",
|
524
|
+
},
|
525
|
+
{
|
526
|
+
internalType: "bool",
|
527
|
+
name: "isPaused",
|
528
|
+
type: "bool",
|
529
|
+
},
|
530
|
+
{
|
531
|
+
internalType: "string",
|
532
|
+
name: "externalLink",
|
533
|
+
type: "string",
|
534
|
+
},
|
535
|
+
],
|
536
|
+
internalType: "struct MockNeutralsRegistry.NeutralsInfo",
|
537
|
+
name: "",
|
538
|
+
type: "tuple",
|
539
|
+
},
|
540
|
+
],
|
541
|
+
stateMutability: "view",
|
542
|
+
type: "function",
|
543
|
+
},
|
544
|
+
{
|
545
|
+
inputs: [],
|
546
|
+
name: "getNeutralsCount",
|
547
|
+
outputs: [
|
548
|
+
{
|
549
|
+
internalType: "uint256",
|
550
|
+
name: "",
|
551
|
+
type: "uint256",
|
552
|
+
},
|
553
|
+
],
|
554
|
+
stateMutability: "view",
|
555
|
+
type: "function",
|
556
|
+
},
|
557
|
+
{
|
558
|
+
inputs: [
|
559
|
+
{
|
560
|
+
internalType: "uint256",
|
561
|
+
name: "number_",
|
562
|
+
type: "uint256",
|
563
|
+
},
|
564
|
+
],
|
565
|
+
name: "getNeutralsSlice",
|
566
|
+
outputs: [
|
567
|
+
{
|
568
|
+
internalType: "address[]",
|
569
|
+
name: "",
|
570
|
+
type: "address[]",
|
571
|
+
},
|
572
|
+
],
|
573
|
+
stateMutability: "view",
|
574
|
+
type: "function",
|
575
|
+
},
|
576
|
+
{
|
577
|
+
inputs: [
|
578
|
+
{
|
579
|
+
internalType: "address",
|
580
|
+
name: "candidate_",
|
581
|
+
type: "address",
|
582
|
+
},
|
583
|
+
],
|
584
|
+
name: "isNeutral",
|
585
|
+
outputs: [
|
586
|
+
{
|
587
|
+
internalType: "bool",
|
588
|
+
name: "",
|
589
|
+
type: "bool",
|
590
|
+
},
|
591
|
+
],
|
592
|
+
stateMutability: "view",
|
593
|
+
type: "function",
|
594
|
+
},
|
595
|
+
{
|
596
|
+
inputs: [
|
597
|
+
{
|
598
|
+
internalType: "address",
|
599
|
+
name: "neutral_",
|
600
|
+
type: "address",
|
601
|
+
},
|
602
|
+
],
|
603
|
+
name: "removeNeutral",
|
604
|
+
outputs: [],
|
605
|
+
stateMutability: "nonpayable",
|
606
|
+
type: "function",
|
607
|
+
},
|
608
|
+
{
|
609
|
+
inputs: [
|
610
|
+
{
|
611
|
+
internalType: "address",
|
612
|
+
name: "governance_",
|
613
|
+
type: "address",
|
614
|
+
},
|
615
|
+
],
|
616
|
+
name: "setGovernance",
|
617
|
+
outputs: [],
|
618
|
+
stateMutability: "nonpayable",
|
619
|
+
type: "function",
|
620
|
+
},
|
621
|
+
{
|
622
|
+
inputs: [
|
623
|
+
{
|
624
|
+
internalType: "address",
|
625
|
+
name: "token_",
|
626
|
+
type: "address",
|
627
|
+
},
|
628
|
+
],
|
629
|
+
name: "setToken",
|
630
|
+
outputs: [],
|
631
|
+
stateMutability: "nonpayable",
|
632
|
+
type: "function",
|
633
|
+
},
|
634
|
+
{
|
635
|
+
inputs: [
|
636
|
+
{
|
637
|
+
internalType: "address",
|
638
|
+
name: "neutral_",
|
639
|
+
type: "address",
|
640
|
+
},
|
641
|
+
{
|
642
|
+
internalType: "uint256",
|
643
|
+
name: "amount_",
|
644
|
+
type: "uint256",
|
645
|
+
},
|
646
|
+
],
|
647
|
+
name: "slashNeutral",
|
648
|
+
outputs: [],
|
649
|
+
stateMutability: "nonpayable",
|
650
|
+
type: "function",
|
651
|
+
},
|
652
|
+
{
|
653
|
+
inputs: [
|
654
|
+
{
|
655
|
+
internalType: "bytes4",
|
656
|
+
name: "interfaceId",
|
657
|
+
type: "bytes4",
|
658
|
+
},
|
659
|
+
],
|
660
|
+
name: "supportsInterface",
|
661
|
+
outputs: [
|
662
|
+
{
|
663
|
+
internalType: "bool",
|
664
|
+
name: "",
|
665
|
+
type: "bool",
|
666
|
+
},
|
667
|
+
],
|
668
|
+
stateMutability: "pure",
|
669
|
+
type: "function",
|
670
|
+
},
|
671
|
+
] as const;
|
672
|
+
|
673
|
+
const _bytecode =
|
674
|
+
"0x6080806040523460155761100c908161001b8239f35b600080fdfe608080604052600436101561001357600080fd5b60003560e01c90816301ffc9a714610c075750806308d8812214610b8e5780630c75325914610905578063144fa6d7146108ce5780633f01c77e146108b05780634b33e582146106aa5780636cd08a931461066b57806387fb530a146105bc578063ab033ea914610585578063dcf2fc39146104bf578063e665169b1461049e578063ed3f77cb14610175578063f4deaca31461015a5763fac8a8c4146100b957600080fd5b34610155576020366003190112610155576002546004358082101561014e57505b6100e381610d04565b906100f16040519283610ce3565b808252601f1961010082610d04565b0136602084013760005b818110610123576040518061011f8582610c5a565b0390f35b8061012f600192610d1b565b838060a01b0391549060031b1c166101478286610fcb565b520161010a565b90506100da565b600080fd5b3461015557604036600319011261015557610173610c9d565b005b34610155576020366003190112610155576004356001600160401b0381116101555736602382011215610155578060040135906101b182610d04565b916101bf6040519384610ce3565b8083526024602084019160051b8301019136831161015557602401905b828210610486578360005b8151811015610173576001600160a01b036102028284610fcb565b5116600052600360205260ff6040600020541615610439575b60405161022781610cc7565b6000815260066020820191600083526040810160008152606082019060008252608083016000815260a08401926001845260c085019260008452604097885198610271818b610ce3565b60168a5275687474703a2f2f746573742e6e65757472616c2e6d6560501b60208b015260e08801998a526001600160a01b036102ad8c8e610fcb565b51166000526004602052600020965187555160018701555160028601555160038501555160048401556102f36005840192511515839060ff801983541691151516179055565b51151561ff0082549160081b169061ff0019161790550190518051906001600160401b038211610423576103278354610dbe565b601f81116103e6575b50602090601f831160011461037b579180610367926001969594600092610370575b50508160011b916000199060031b1c19161790565b90555b016101e7565b015190508780610352565b90601f1983169184600052816000209260005b8181106103ce5750916001969594929183889593106103b5575b505050811b01905561036a565b015160001960f88460031b161c191690558680806103a8565b9293602060018192878601518155019501930161038e565b61041390846000526020600020601f850160051c81019160208610610419575b601f0160051c0190610df8565b85610330565b9091508190610406565b634e487b7160e01b600052604160045260246000fd5b6104556001600160a01b0361044e8385610fcb565b5116610d4c565b6001600160a01b036104678284610fcb565b511660005260036020526040600020600160ff1982541617905561021b565b6020809161049384610cb3565b8152019101906101dc565b34610155576020366003190112610155576101736104ba610c9d565b610e89565b34610155576040366003190112610155576004356001600160401b03811161015557366023820112156101555780600401356001600160401b038111610155573660248260051b8401011161015557604051908060408301604084525260246060830193019060005b81811061055f5760243560208501527f4c7cb22838e004dd47d1cb8aabab908f17a2851609c953fb7547c066d5e41acf84860385a1005b909193602080600192838060a01b0361057789610cb3565b168152019501929101610528565b34610155576020366003190112610155576001600160a01b036105a6610c9d565b1660018060a01b03196000541617600055600080f35b346101555760003660031901126101555760005b60025481101561063b57806105e6600192610d1b565b838060a01b0391549060031b1c166000526003602052604060002060ff19815416905561061281610d1b565b838060a01b0391549060031b1c1660005260046020526106356040600020610e0f565b016105d0565b60025460006002558061064a57005b600260005261017390600080516020610fe083398151915290810190610df8565b34610155576020366003190112610155576001600160a01b0361068c610c9d565b166000526003602052602060ff604060002054166040519015158152f35b34610155576020366003190112610155576106c3610c9d565b606060e06040516106d381610cc7565b60008152600060208201526000604082015260008382015260006080820152600060a0820152600060c0820152015260018060a01b0316600052600460205260406000206040519061072482610cc7565b80548252600181015490602083019182526002810154906040840191825260038101546060850190815260048201549060808601918252600583015493600660a088019460ff87161515865260ff60c08a019760081c161515875201956040519687600082549261079484610dbe565b808452936001811690811561088e5750600114610848575b506107b992500388610ce3565b60e0880196875260405197602089525160208901525160408801525160608701525160808601525160a085015251151560c084015251151560e08301525161010080830152818151918261012083015260005b83811061082f575050816000610140809484010152601f80199101168101030190f35b602082820181015161014087840101528593500161080c565b90506000929192526020600020906000915b8183106108735750509060206107b9928201018b6107ac565b8060209294838560019454920101520191019091899261085a565b9050602092506107b994915060ff191682840152151560051b8201018b6107ac565b34610155576000366003190112610155576020600254604051908152f35b34610155576020366003190112610155576001600160a01b036108ef610c9d565b1660018060a01b03196001541617600155600080f35b346101555760403660031901126101555761091e610c9d565b6024356001600160401b0381116101555736602382011215610155578060040135916001600160401b038311610155573660248484010111610155576001600160a01b03811660008181526003602052604090205490919060ff1615610b66575b506040519061098d82610cc7565b600082526020820190600082526040830160008152606084016000815260808501916000835260a08601946001865260c087019460008652601f19601f8b0116602001986040519a6109e08c9b8c610ce3565b808b528060009b60248d940190602001378b016020015260e08801998a528852600460205260408820965187555160018701555160028601555160038501555160048401556005830191511515610a4390839060ff801983541691151516179055565b51151581549060081b61ff00169061ff00191617905560060191519182516001600160401b038111610b5257610a798254610dbe565b601f8111610b22575b506020601f8211600114610ac35781908495610ab3949592610ab85750508160011b916000199060031b1c19161790565b905580f35b015190508580610352565b82845280842090601f198316855b818110610b0a57509583600195969710610af1575b505050811b01905580f35b015160001960f88460031b161c19169055848080610ae6565b9192602060018192868b015181550194019201610ad1565b610b4c9083855260208520601f840160051c8101916020851061041957601f0160051c0190610df8565b84610a82565b634e487b7160e01b83526041600452602483fd5b610b6f90610d4c565b8060005260036020526040600020600160ff198254161790558361097f565b34610155576000366003190112610155576040516002805480835260009182526020830191600080516020610fe083398151915291905b818110610be85761011f85610bdc81870382610ce3565b60405191829182610c5a565b82546001600160a01b0316845260209093019260019283019201610bc5565b34610155576020366003190112610155576004359063ffffffff60e01b821680920361015557602091638135b5b360e01b8114908115610c49575b5015158152f35b6301ffc9a760e01b14905083610c42565b602060408183019282815284518094520192019060005b818110610c7e5750505090565b82516001600160a01b0316845260209384019390920191600101610c71565b600435906001600160a01b038216820361015557565b35906001600160a01b038216820361015557565b61010081019081106001600160401b0382111761042357604052565b90601f801991011681019081106001600160401b0382111761042357604052565b6001600160401b0381116104235760051b60200190565b600254811015610d3657600260005260206000200190600090565b634e487b7160e01b600052603260045260246000fd5b6002549190600160401b8310156104235760018301600255600092600254811015610daa576002909352600080516020610fe083398151915290920180546001600160a01b0319166001600160a01b0390931692909217909155565b565b634e487b7160e01b84526032600452602484fd5b90600182811c92168015610dee575b6020831014610dd857565b634e487b7160e01b600052602260045260246000fd5b91607f1691610dcd565b818110610e03575050565b60008155600101610df8565b60069060008155600060018201556000600282015560006003820155600060048201556000600582015501610e448154610dbe565b9081610e4e575050565b81601f60009311600114610e60575055565b81835260208320610e7c91601f0160051c810190600101610df8565b8082528160208120915555565b6001600160a01b031660008181526003602052604090205460ff1615610fc8576002549060005b828110610ee6575b508091506000526003602052604060002060ff1981541690556000526004602052610da86040600020610e0f565b81610ef082610d1b565b905460039190911b1c6001600160a01b031614610f0f57600101610eb0565b9091600019810191908211610fb257610f45610f2d610f6993610d1b565b905460039190911b1c6001600160a01b031691610d1b565b81546001600160a01b0393841660039290921b91821b9390911b1916919091179055565b6002548015610f9c5760001901610f7f81610d1b565b81549060018060a01b039060031b1b191690556002558038610eb8565b634e487b7160e01b600052603160045260246000fd5b634e487b7160e01b600052601160045260246000fd5b50565b8051821015610d365760209160051b01019056fe405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5acea164736f6c634300081e000a";
|
675
|
+
|
676
|
+
type MockNeutralsRegistryConstructorParams =
|
677
|
+
| [signer?: Signer]
|
678
|
+
| ConstructorParameters<typeof ContractFactory>;
|
679
|
+
|
680
|
+
const isSuperArgs = (
|
681
|
+
xs: MockNeutralsRegistryConstructorParams
|
682
|
+
): xs is ConstructorParameters<typeof ContractFactory> => xs.length > 1;
|
683
|
+
|
684
|
+
export class MockNeutralsRegistry__factory extends ContractFactory {
|
685
|
+
constructor(...args: MockNeutralsRegistryConstructorParams) {
|
686
|
+
if (isSuperArgs(args)) {
|
687
|
+
super(...args);
|
688
|
+
} else {
|
689
|
+
super(_abi, _bytecode, args[0]);
|
690
|
+
}
|
691
|
+
this.contractName = "MockNeutralsRegistry";
|
692
|
+
}
|
693
|
+
|
694
|
+
override getDeployTransaction(
|
695
|
+
overrides?: NonPayableOverrides & { from?: string }
|
696
|
+
): Promise<ContractDeployTransaction> {
|
697
|
+
return super.getDeployTransaction(overrides || {});
|
698
|
+
}
|
699
|
+
override deploy(overrides?: NonPayableOverrides & { from?: string }) {
|
700
|
+
return super.deploy(overrides || {}) as Promise<
|
701
|
+
MockNeutralsRegistry & {
|
702
|
+
deploymentTransaction(): ContractTransactionResponse;
|
703
|
+
}
|
704
|
+
>;
|
705
|
+
}
|
706
|
+
override connect(
|
707
|
+
runner: ContractRunner | null
|
708
|
+
): MockNeutralsRegistry__factory {
|
709
|
+
return super.connect(runner) as MockNeutralsRegistry__factory;
|
710
|
+
}
|
711
|
+
static readonly contractName: "MockNeutralsRegistry";
|
712
|
+
|
713
|
+
public readonly contractName: "MockNeutralsRegistry";
|
714
|
+
|
715
|
+
static readonly bytecode = _bytecode;
|
716
|
+
static readonly abi = _abi;
|
717
|
+
static createInterface(): MockNeutralsRegistryInterface {
|
718
|
+
return new Interface(_abi) as MockNeutralsRegistryInterface;
|
719
|
+
}
|
720
|
+
static connect(
|
721
|
+
address: string,
|
722
|
+
runner?: ContractRunner | null
|
723
|
+
): MockNeutralsRegistry {
|
724
|
+
return new Contract(
|
725
|
+
address,
|
726
|
+
_abi,
|
727
|
+
runner
|
728
|
+
) as unknown as MockNeutralsRegistry;
|
729
|
+
}
|
730
|
+
}
|