@gainsnetwork/sdk 1.6.9 → 1.7.0-rc1

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.
Files changed (39) hide show
  1. package/lib/constants.d.ts +1 -0
  2. package/lib/constants.js +2 -1
  3. package/lib/contracts/utils/pairs.js +1 -0
  4. package/lib/markets/schedules/holidays.js +2 -2
  5. package/lib/trade/types.d.ts +2 -1
  6. package/lib/trade/types.js +1 -0
  7. package/package.json +1 -1
  8. package/lib/contracts/types/generated/GFarmTradingStorageV5.d.ts +0 -1911
  9. package/lib/contracts/types/generated/GFarmTradingStorageV5.js +0 -2
  10. package/lib/contracts/types/generated/GNSBorrowingFees.d.ts +0 -1067
  11. package/lib/contracts/types/generated/GNSBorrowingFees.js +0 -2
  12. package/lib/contracts/types/generated/GNSNftRewardsV6.d.ts +0 -533
  13. package/lib/contracts/types/generated/GNSNftRewardsV6.js +0 -2
  14. package/lib/contracts/types/generated/GNSNftRewardsV6_3_1.d.ts +0 -613
  15. package/lib/contracts/types/generated/GNSNftRewardsV6_3_1.js +0 -2
  16. package/lib/contracts/types/generated/GNSTrading.d.ts +0 -758
  17. package/lib/contracts/types/generated/GNSTrading.js +0 -2
  18. package/lib/contracts/types/generated/GNSTradingCallbacks.d.ts +0 -875
  19. package/lib/contracts/types/generated/GNSTradingCallbacks.js +0 -2
  20. package/lib/contracts/types/generated/GNSTradingStorage.d.ts +0 -1387
  21. package/lib/contracts/types/generated/GNSTradingStorage.js +0 -2
  22. package/lib/contracts/types/generated/GTokenV6_3_2.d.ts +0 -1838
  23. package/lib/contracts/types/generated/GTokenV6_3_2.js +0 -2
  24. package/lib/contracts/types/generated/factories/GFarmTradingStorageV5__factory.d.ts +0 -83
  25. package/lib/contracts/types/generated/factories/GFarmTradingStorageV5__factory.js +0 -2691
  26. package/lib/contracts/types/generated/factories/GNSBorrowingFees__factory.d.ts +0 -124
  27. package/lib/contracts/types/generated/factories/GNSBorrowingFees__factory.js +0 -1784
  28. package/lib/contracts/types/generated/factories/GNSNftRewardsV6_3_1__factory.d.ts +0 -100
  29. package/lib/contracts/types/generated/factories/GNSNftRewardsV6_3_1__factory.js +0 -1116
  30. package/lib/contracts/types/generated/factories/GNSNftRewardsV6__factory.d.ts +0 -100
  31. package/lib/contracts/types/generated/factories/GNSNftRewardsV6__factory.js +0 -1003
  32. package/lib/contracts/types/generated/factories/GNSTradingCallbacks__factory.d.ts +0 -113
  33. package/lib/contracts/types/generated/factories/GNSTradingCallbacks__factory.js +0 -1428
  34. package/lib/contracts/types/generated/factories/GNSTradingStorage__factory.d.ts +0 -96
  35. package/lib/contracts/types/generated/factories/GNSTradingStorage__factory.js +0 -2241
  36. package/lib/contracts/types/generated/factories/GNSTrading__factory.d.ts +0 -95
  37. package/lib/contracts/types/generated/factories/GNSTrading__factory.js +0 -1071
  38. package/lib/contracts/types/generated/factories/GTokenV6_3_2__factory.d.ts +0 -110
  39. package/lib/contracts/types/generated/factories/GTokenV6_3_2__factory.js +0 -2682
@@ -1,1784 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.GNSBorrowingFees__factory = void 0;
4
- /* Autogenerated file. Do not edit manually. */
5
- /* tslint:disable */
6
- /* eslint-disable */
7
- const ethers_1 = require("ethers");
8
- const _abi = [
9
- {
10
- inputs: [],
11
- name: "BlockOrder",
12
- type: "error",
13
- },
14
- {
15
- inputs: [],
16
- name: "Overflow",
17
- type: "error",
18
- },
19
- {
20
- inputs: [],
21
- name: "WrongAccess",
22
- type: "error",
23
- },
24
- {
25
- inputs: [],
26
- name: "WrongExponent",
27
- type: "error",
28
- },
29
- {
30
- inputs: [],
31
- name: "WrongLength",
32
- type: "error",
33
- },
34
- {
35
- inputs: [],
36
- name: "WrongParams",
37
- type: "error",
38
- },
39
- {
40
- inputs: [],
41
- name: "WrongSlot",
42
- type: "error",
43
- },
44
- {
45
- inputs: [],
46
- name: "ZeroGroup",
47
- type: "error",
48
- },
49
- {
50
- anonymous: false,
51
- inputs: [
52
- {
53
- indexed: true,
54
- internalType: "uint16",
55
- name: "groupIndex",
56
- type: "uint16",
57
- },
58
- {
59
- indexed: false,
60
- internalType: "uint256",
61
- name: "currentBlock",
62
- type: "uint256",
63
- },
64
- {
65
- indexed: false,
66
- internalType: "uint64",
67
- name: "accFeeLong",
68
- type: "uint64",
69
- },
70
- {
71
- indexed: false,
72
- internalType: "uint64",
73
- name: "accFeeShort",
74
- type: "uint64",
75
- },
76
- ],
77
- name: "GroupAccFeesUpdated",
78
- type: "event",
79
- },
80
- {
81
- anonymous: false,
82
- inputs: [
83
- {
84
- indexed: true,
85
- internalType: "uint16",
86
- name: "groupIndex",
87
- type: "uint16",
88
- },
89
- {
90
- indexed: true,
91
- internalType: "bool",
92
- name: "long",
93
- type: "bool",
94
- },
95
- {
96
- indexed: true,
97
- internalType: "bool",
98
- name: "increase",
99
- type: "bool",
100
- },
101
- {
102
- indexed: false,
103
- internalType: "uint112",
104
- name: "amount",
105
- type: "uint112",
106
- },
107
- {
108
- indexed: false,
109
- internalType: "uint112",
110
- name: "oiLong",
111
- type: "uint112",
112
- },
113
- {
114
- indexed: false,
115
- internalType: "uint112",
116
- name: "oiShort",
117
- type: "uint112",
118
- },
119
- ],
120
- name: "GroupOiUpdated",
121
- type: "event",
122
- },
123
- {
124
- anonymous: false,
125
- inputs: [
126
- {
127
- indexed: true,
128
- internalType: "uint16",
129
- name: "groupIndex",
130
- type: "uint16",
131
- },
132
- {
133
- indexed: false,
134
- internalType: "uint32",
135
- name: "feePerBlock",
136
- type: "uint32",
137
- },
138
- {
139
- indexed: false,
140
- internalType: "uint72",
141
- name: "maxOi",
142
- type: "uint72",
143
- },
144
- {
145
- indexed: false,
146
- internalType: "uint48",
147
- name: "feeExponent",
148
- type: "uint48",
149
- },
150
- ],
151
- name: "GroupUpdated",
152
- type: "event",
153
- },
154
- {
155
- anonymous: false,
156
- inputs: [
157
- {
158
- indexed: false,
159
- internalType: "uint8",
160
- name: "version",
161
- type: "uint8",
162
- },
163
- ],
164
- name: "Initialized",
165
- type: "event",
166
- },
167
- {
168
- anonymous: false,
169
- inputs: [
170
- {
171
- indexed: true,
172
- internalType: "uint256",
173
- name: "pairIndex",
174
- type: "uint256",
175
- },
176
- {
177
- indexed: false,
178
- internalType: "uint256",
179
- name: "currentBlock",
180
- type: "uint256",
181
- },
182
- {
183
- indexed: false,
184
- internalType: "uint64",
185
- name: "accFeeLong",
186
- type: "uint64",
187
- },
188
- {
189
- indexed: false,
190
- internalType: "uint64",
191
- name: "accFeeShort",
192
- type: "uint64",
193
- },
194
- ],
195
- name: "PairAccFeesUpdated",
196
- type: "event",
197
- },
198
- {
199
- anonymous: false,
200
- inputs: [
201
- {
202
- indexed: true,
203
- internalType: "uint256",
204
- name: "pairIndex",
205
- type: "uint256",
206
- },
207
- {
208
- indexed: true,
209
- internalType: "uint16",
210
- name: "prevGroupIndex",
211
- type: "uint16",
212
- },
213
- {
214
- indexed: true,
215
- internalType: "uint16",
216
- name: "newGroupIndex",
217
- type: "uint16",
218
- },
219
- ],
220
- name: "PairGroupUpdated",
221
- type: "event",
222
- },
223
- {
224
- anonymous: false,
225
- inputs: [
226
- {
227
- indexed: true,
228
- internalType: "uint256",
229
- name: "pairIndex",
230
- type: "uint256",
231
- },
232
- {
233
- indexed: true,
234
- internalType: "uint16",
235
- name: "groupIndex",
236
- type: "uint16",
237
- },
238
- {
239
- indexed: false,
240
- internalType: "uint32",
241
- name: "feePerBlock",
242
- type: "uint32",
243
- },
244
- {
245
- indexed: false,
246
- internalType: "uint48",
247
- name: "feeExponent",
248
- type: "uint48",
249
- },
250
- {
251
- indexed: false,
252
- internalType: "uint72",
253
- name: "maxOi",
254
- type: "uint72",
255
- },
256
- ],
257
- name: "PairParamsUpdated",
258
- type: "event",
259
- },
260
- {
261
- anonymous: false,
262
- inputs: [
263
- {
264
- indexed: true,
265
- internalType: "address",
266
- name: "trader",
267
- type: "address",
268
- },
269
- {
270
- indexed: true,
271
- internalType: "uint256",
272
- name: "pairIndex",
273
- type: "uint256",
274
- },
275
- {
276
- indexed: false,
277
- internalType: "uint256",
278
- name: "index",
279
- type: "uint256",
280
- },
281
- {
282
- indexed: false,
283
- internalType: "bool",
284
- name: "open",
285
- type: "bool",
286
- },
287
- {
288
- indexed: false,
289
- internalType: "bool",
290
- name: "long",
291
- type: "bool",
292
- },
293
- {
294
- indexed: false,
295
- internalType: "uint256",
296
- name: "positionSizeDai",
297
- type: "uint256",
298
- },
299
- ],
300
- name: "TradeActionHandled",
301
- type: "event",
302
- },
303
- {
304
- anonymous: false,
305
- inputs: [
306
- {
307
- indexed: true,
308
- internalType: "address",
309
- name: "trader",
310
- type: "address",
311
- },
312
- {
313
- indexed: true,
314
- internalType: "uint256",
315
- name: "pairIndex",
316
- type: "uint256",
317
- },
318
- {
319
- indexed: false,
320
- internalType: "uint256",
321
- name: "index",
322
- type: "uint256",
323
- },
324
- {
325
- indexed: false,
326
- internalType: "uint64",
327
- name: "initialPairAccFee",
328
- type: "uint64",
329
- },
330
- {
331
- indexed: false,
332
- internalType: "uint64",
333
- name: "initialGroupAccFee",
334
- type: "uint64",
335
- },
336
- ],
337
- name: "TradeInitialAccFeesStored",
338
- type: "event",
339
- },
340
- {
341
- inputs: [],
342
- name: "collateralConfig",
343
- outputs: [
344
- {
345
- internalType: "uint128",
346
- name: "precision",
347
- type: "uint128",
348
- },
349
- {
350
- internalType: "uint128",
351
- name: "precisionDelta",
352
- type: "uint128",
353
- },
354
- ],
355
- stateMutability: "view",
356
- type: "function",
357
- },
358
- {
359
- inputs: [],
360
- name: "getAllPairs",
361
- outputs: [
362
- {
363
- components: [
364
- {
365
- components: [
366
- {
367
- internalType: "uint16",
368
- name: "groupIndex",
369
- type: "uint16",
370
- },
371
- {
372
- internalType: "uint48",
373
- name: "block",
374
- type: "uint48",
375
- },
376
- {
377
- internalType: "uint64",
378
- name: "initialAccFeeLong",
379
- type: "uint64",
380
- },
381
- {
382
- internalType: "uint64",
383
- name: "initialAccFeeShort",
384
- type: "uint64",
385
- },
386
- {
387
- internalType: "uint64",
388
- name: "prevGroupAccFeeLong",
389
- type: "uint64",
390
- },
391
- {
392
- internalType: "uint64",
393
- name: "prevGroupAccFeeShort",
394
- type: "uint64",
395
- },
396
- {
397
- internalType: "uint64",
398
- name: "pairAccFeeLong",
399
- type: "uint64",
400
- },
401
- {
402
- internalType: "uint64",
403
- name: "pairAccFeeShort",
404
- type: "uint64",
405
- },
406
- {
407
- internalType: "uint64",
408
- name: "_placeholder",
409
- type: "uint64",
410
- },
411
- ],
412
- internalType: "struct IGNSBorrowingFees.PairGroup[]",
413
- name: "groups",
414
- type: "tuple[]",
415
- },
416
- {
417
- internalType: "uint32",
418
- name: "feePerBlock",
419
- type: "uint32",
420
- },
421
- {
422
- internalType: "uint64",
423
- name: "accFeeLong",
424
- type: "uint64",
425
- },
426
- {
427
- internalType: "uint64",
428
- name: "accFeeShort",
429
- type: "uint64",
430
- },
431
- {
432
- internalType: "uint48",
433
- name: "accLastUpdatedBlock",
434
- type: "uint48",
435
- },
436
- {
437
- internalType: "uint48",
438
- name: "feeExponent",
439
- type: "uint48",
440
- },
441
- {
442
- internalType: "uint256",
443
- name: "lastAccBlockWeightedMarketCap",
444
- type: "uint256",
445
- },
446
- ],
447
- internalType: "struct IGNSBorrowingFees.Pair[]",
448
- name: "",
449
- type: "tuple[]",
450
- },
451
- {
452
- components: [
453
- {
454
- internalType: "uint72",
455
- name: "long",
456
- type: "uint72",
457
- },
458
- {
459
- internalType: "uint72",
460
- name: "short",
461
- type: "uint72",
462
- },
463
- {
464
- internalType: "uint72",
465
- name: "max",
466
- type: "uint72",
467
- },
468
- {
469
- internalType: "uint40",
470
- name: "_placeholder",
471
- type: "uint40",
472
- },
473
- ],
474
- internalType: "struct IGNSBorrowingFees.PairOi[]",
475
- name: "",
476
- type: "tuple[]",
477
- },
478
- ],
479
- stateMutability: "view",
480
- type: "function",
481
- },
482
- {
483
- inputs: [
484
- {
485
- internalType: "uint256",
486
- name: "pairIndex",
487
- type: "uint256",
488
- },
489
- ],
490
- name: "getCollateralPairMaxOi",
491
- outputs: [
492
- {
493
- internalType: "uint256",
494
- name: "",
495
- type: "uint256",
496
- },
497
- ],
498
- stateMutability: "view",
499
- type: "function",
500
- },
501
- {
502
- inputs: [
503
- {
504
- internalType: "uint16",
505
- name: "groupIndex",
506
- type: "uint16",
507
- },
508
- ],
509
- name: "getGroup",
510
- outputs: [
511
- {
512
- components: [
513
- {
514
- internalType: "uint112",
515
- name: "oiLong",
516
- type: "uint112",
517
- },
518
- {
519
- internalType: "uint112",
520
- name: "oiShort",
521
- type: "uint112",
522
- },
523
- {
524
- internalType: "uint32",
525
- name: "feePerBlock",
526
- type: "uint32",
527
- },
528
- {
529
- internalType: "uint64",
530
- name: "accFeeLong",
531
- type: "uint64",
532
- },
533
- {
534
- internalType: "uint64",
535
- name: "accFeeShort",
536
- type: "uint64",
537
- },
538
- {
539
- internalType: "uint48",
540
- name: "accLastUpdatedBlock",
541
- type: "uint48",
542
- },
543
- {
544
- internalType: "uint80",
545
- name: "maxOi",
546
- type: "uint80",
547
- },
548
- {
549
- internalType: "uint256",
550
- name: "lastAccBlockWeightedMarketCap",
551
- type: "uint256",
552
- },
553
- ],
554
- internalType: "struct IGNSBorrowingFees.Group",
555
- name: "",
556
- type: "tuple",
557
- },
558
- {
559
- internalType: "uint48",
560
- name: "",
561
- type: "uint48",
562
- },
563
- ],
564
- stateMutability: "view",
565
- type: "function",
566
- },
567
- {
568
- inputs: [
569
- {
570
- internalType: "uint16",
571
- name: "groupIndex",
572
- type: "uint16",
573
- },
574
- {
575
- internalType: "uint256",
576
- name: "currentBlock",
577
- type: "uint256",
578
- },
579
- {
580
- internalType: "bool",
581
- name: "long",
582
- type: "bool",
583
- },
584
- ],
585
- name: "getGroupPendingAccFee",
586
- outputs: [
587
- {
588
- internalType: "uint64",
589
- name: "accFee",
590
- type: "uint64",
591
- },
592
- ],
593
- stateMutability: "view",
594
- type: "function",
595
- },
596
- {
597
- inputs: [
598
- {
599
- internalType: "uint16",
600
- name: "groupIndex",
601
- type: "uint16",
602
- },
603
- {
604
- internalType: "uint256",
605
- name: "currentBlock",
606
- type: "uint256",
607
- },
608
- ],
609
- name: "getGroupPendingAccFees",
610
- outputs: [
611
- {
612
- internalType: "uint64",
613
- name: "accFeeLong",
614
- type: "uint64",
615
- },
616
- {
617
- internalType: "uint64",
618
- name: "accFeeShort",
619
- type: "uint64",
620
- },
621
- {
622
- internalType: "uint64",
623
- name: "groupAccFeeDelta",
624
- type: "uint64",
625
- },
626
- ],
627
- stateMutability: "view",
628
- type: "function",
629
- },
630
- {
631
- inputs: [
632
- {
633
- internalType: "uint16[]",
634
- name: "indices",
635
- type: "uint16[]",
636
- },
637
- ],
638
- name: "getGroups",
639
- outputs: [
640
- {
641
- components: [
642
- {
643
- internalType: "uint112",
644
- name: "oiLong",
645
- type: "uint112",
646
- },
647
- {
648
- internalType: "uint112",
649
- name: "oiShort",
650
- type: "uint112",
651
- },
652
- {
653
- internalType: "uint32",
654
- name: "feePerBlock",
655
- type: "uint32",
656
- },
657
- {
658
- internalType: "uint64",
659
- name: "accFeeLong",
660
- type: "uint64",
661
- },
662
- {
663
- internalType: "uint64",
664
- name: "accFeeShort",
665
- type: "uint64",
666
- },
667
- {
668
- internalType: "uint48",
669
- name: "accLastUpdatedBlock",
670
- type: "uint48",
671
- },
672
- {
673
- internalType: "uint80",
674
- name: "maxOi",
675
- type: "uint80",
676
- },
677
- {
678
- internalType: "uint256",
679
- name: "lastAccBlockWeightedMarketCap",
680
- type: "uint256",
681
- },
682
- ],
683
- internalType: "struct IGNSBorrowingFees.Group[]",
684
- name: "",
685
- type: "tuple[]",
686
- },
687
- {
688
- internalType: "uint48[]",
689
- name: "",
690
- type: "uint48[]",
691
- },
692
- ],
693
- stateMutability: "view",
694
- type: "function",
695
- },
696
- {
697
- inputs: [
698
- {
699
- internalType: "uint256",
700
- name: "pairIndex",
701
- type: "uint256",
702
- },
703
- ],
704
- name: "getPair",
705
- outputs: [
706
- {
707
- components: [
708
- {
709
- components: [
710
- {
711
- internalType: "uint16",
712
- name: "groupIndex",
713
- type: "uint16",
714
- },
715
- {
716
- internalType: "uint48",
717
- name: "block",
718
- type: "uint48",
719
- },
720
- {
721
- internalType: "uint64",
722
- name: "initialAccFeeLong",
723
- type: "uint64",
724
- },
725
- {
726
- internalType: "uint64",
727
- name: "initialAccFeeShort",
728
- type: "uint64",
729
- },
730
- {
731
- internalType: "uint64",
732
- name: "prevGroupAccFeeLong",
733
- type: "uint64",
734
- },
735
- {
736
- internalType: "uint64",
737
- name: "prevGroupAccFeeShort",
738
- type: "uint64",
739
- },
740
- {
741
- internalType: "uint64",
742
- name: "pairAccFeeLong",
743
- type: "uint64",
744
- },
745
- {
746
- internalType: "uint64",
747
- name: "pairAccFeeShort",
748
- type: "uint64",
749
- },
750
- {
751
- internalType: "uint64",
752
- name: "_placeholder",
753
- type: "uint64",
754
- },
755
- ],
756
- internalType: "struct IGNSBorrowingFees.PairGroup[]",
757
- name: "groups",
758
- type: "tuple[]",
759
- },
760
- {
761
- internalType: "uint32",
762
- name: "feePerBlock",
763
- type: "uint32",
764
- },
765
- {
766
- internalType: "uint64",
767
- name: "accFeeLong",
768
- type: "uint64",
769
- },
770
- {
771
- internalType: "uint64",
772
- name: "accFeeShort",
773
- type: "uint64",
774
- },
775
- {
776
- internalType: "uint48",
777
- name: "accLastUpdatedBlock",
778
- type: "uint48",
779
- },
780
- {
781
- internalType: "uint48",
782
- name: "feeExponent",
783
- type: "uint48",
784
- },
785
- {
786
- internalType: "uint256",
787
- name: "lastAccBlockWeightedMarketCap",
788
- type: "uint256",
789
- },
790
- ],
791
- internalType: "struct IGNSBorrowingFees.Pair",
792
- name: "",
793
- type: "tuple",
794
- },
795
- {
796
- components: [
797
- {
798
- internalType: "uint72",
799
- name: "long",
800
- type: "uint72",
801
- },
802
- {
803
- internalType: "uint72",
804
- name: "short",
805
- type: "uint72",
806
- },
807
- {
808
- internalType: "uint72",
809
- name: "max",
810
- type: "uint72",
811
- },
812
- {
813
- internalType: "uint40",
814
- name: "_placeholder",
815
- type: "uint40",
816
- },
817
- ],
818
- internalType: "struct IGNSBorrowingFees.PairOi",
819
- name: "",
820
- type: "tuple",
821
- },
822
- ],
823
- stateMutability: "view",
824
- type: "function",
825
- },
826
- {
827
- inputs: [
828
- {
829
- internalType: "uint256",
830
- name: "i",
831
- type: "uint256",
832
- },
833
- {
834
- components: [
835
- {
836
- internalType: "uint16",
837
- name: "groupIndex",
838
- type: "uint16",
839
- },
840
- {
841
- internalType: "uint48",
842
- name: "block",
843
- type: "uint48",
844
- },
845
- {
846
- internalType: "uint64",
847
- name: "initialAccFeeLong",
848
- type: "uint64",
849
- },
850
- {
851
- internalType: "uint64",
852
- name: "initialAccFeeShort",
853
- type: "uint64",
854
- },
855
- {
856
- internalType: "uint64",
857
- name: "prevGroupAccFeeLong",
858
- type: "uint64",
859
- },
860
- {
861
- internalType: "uint64",
862
- name: "prevGroupAccFeeShort",
863
- type: "uint64",
864
- },
865
- {
866
- internalType: "uint64",
867
- name: "pairAccFeeLong",
868
- type: "uint64",
869
- },
870
- {
871
- internalType: "uint64",
872
- name: "pairAccFeeShort",
873
- type: "uint64",
874
- },
875
- {
876
- internalType: "uint64",
877
- name: "_placeholder",
878
- type: "uint64",
879
- },
880
- ],
881
- internalType: "struct IGNSBorrowingFees.PairGroup[]",
882
- name: "pairGroups",
883
- type: "tuple[]",
884
- },
885
- {
886
- components: [
887
- {
888
- internalType: "uint64",
889
- name: "accPairFee",
890
- type: "uint64",
891
- },
892
- {
893
- internalType: "uint64",
894
- name: "accGroupFee",
895
- type: "uint64",
896
- },
897
- {
898
- internalType: "uint48",
899
- name: "block",
900
- type: "uint48",
901
- },
902
- {
903
- internalType: "uint80",
904
- name: "_placeholder",
905
- type: "uint80",
906
- },
907
- ],
908
- internalType: "struct IGNSBorrowingFees.InitialAccFees",
909
- name: "initialFees",
910
- type: "tuple",
911
- },
912
- {
913
- internalType: "uint256",
914
- name: "pairIndex",
915
- type: "uint256",
916
- },
917
- {
918
- internalType: "bool",
919
- name: "long",
920
- type: "bool",
921
- },
922
- {
923
- internalType: "uint256",
924
- name: "currentBlock",
925
- type: "uint256",
926
- },
927
- ],
928
- name: "getPairGroupAccFeesDeltas",
929
- outputs: [
930
- {
931
- internalType: "uint64",
932
- name: "deltaGroup",
933
- type: "uint64",
934
- },
935
- {
936
- internalType: "uint64",
937
- name: "deltaPair",
938
- type: "uint64",
939
- },
940
- {
941
- internalType: "bool",
942
- name: "beforeTradeOpen",
943
- type: "bool",
944
- },
945
- ],
946
- stateMutability: "view",
947
- type: "function",
948
- },
949
- {
950
- inputs: [
951
- {
952
- internalType: "uint256",
953
- name: "pairIndex",
954
- type: "uint256",
955
- },
956
- ],
957
- name: "getPairGroupIndex",
958
- outputs: [
959
- {
960
- internalType: "uint16",
961
- name: "groupIndex",
962
- type: "uint16",
963
- },
964
- ],
965
- stateMutability: "view",
966
- type: "function",
967
- },
968
- {
969
- inputs: [
970
- {
971
- internalType: "uint256",
972
- name: "pairIndex",
973
- type: "uint256",
974
- },
975
- ],
976
- name: "getPairMaxOi",
977
- outputs: [
978
- {
979
- internalType: "uint256",
980
- name: "",
981
- type: "uint256",
982
- },
983
- ],
984
- stateMutability: "view",
985
- type: "function",
986
- },
987
- {
988
- inputs: [
989
- {
990
- internalType: "uint256",
991
- name: "pairIndex",
992
- type: "uint256",
993
- },
994
- ],
995
- name: "getPairOpenInterestDai",
996
- outputs: [
997
- {
998
- internalType: "uint256",
999
- name: "",
1000
- type: "uint256",
1001
- },
1002
- {
1003
- internalType: "uint256",
1004
- name: "",
1005
- type: "uint256",
1006
- },
1007
- ],
1008
- stateMutability: "view",
1009
- type: "function",
1010
- },
1011
- {
1012
- inputs: [
1013
- {
1014
- internalType: "uint256",
1015
- name: "pairIndex",
1016
- type: "uint256",
1017
- },
1018
- {
1019
- internalType: "uint256",
1020
- name: "currentBlock",
1021
- type: "uint256",
1022
- },
1023
- {
1024
- internalType: "bool",
1025
- name: "long",
1026
- type: "bool",
1027
- },
1028
- ],
1029
- name: "getPairPendingAccFee",
1030
- outputs: [
1031
- {
1032
- internalType: "uint64",
1033
- name: "accFee",
1034
- type: "uint64",
1035
- },
1036
- ],
1037
- stateMutability: "view",
1038
- type: "function",
1039
- },
1040
- {
1041
- inputs: [
1042
- {
1043
- internalType: "uint256",
1044
- name: "pairIndex",
1045
- type: "uint256",
1046
- },
1047
- {
1048
- internalType: "uint256",
1049
- name: "currentBlock",
1050
- type: "uint256",
1051
- },
1052
- ],
1053
- name: "getPairPendingAccFees",
1054
- outputs: [
1055
- {
1056
- internalType: "uint64",
1057
- name: "accFeeLong",
1058
- type: "uint64",
1059
- },
1060
- {
1061
- internalType: "uint64",
1062
- name: "accFeeShort",
1063
- type: "uint64",
1064
- },
1065
- {
1066
- internalType: "uint64",
1067
- name: "pairAccFeeDelta",
1068
- type: "uint64",
1069
- },
1070
- ],
1071
- stateMutability: "view",
1072
- type: "function",
1073
- },
1074
- {
1075
- inputs: [
1076
- {
1077
- components: [
1078
- {
1079
- internalType: "uint64",
1080
- name: "accFeeLong",
1081
- type: "uint64",
1082
- },
1083
- {
1084
- internalType: "uint64",
1085
- name: "accFeeShort",
1086
- type: "uint64",
1087
- },
1088
- {
1089
- internalType: "uint256",
1090
- name: "oiLong",
1091
- type: "uint256",
1092
- },
1093
- {
1094
- internalType: "uint256",
1095
- name: "oiShort",
1096
- type: "uint256",
1097
- },
1098
- {
1099
- internalType: "uint32",
1100
- name: "feePerBlock",
1101
- type: "uint32",
1102
- },
1103
- {
1104
- internalType: "uint256",
1105
- name: "currentBlock",
1106
- type: "uint256",
1107
- },
1108
- {
1109
- internalType: "uint256",
1110
- name: "accLastUpdatedBlock",
1111
- type: "uint256",
1112
- },
1113
- {
1114
- internalType: "uint72",
1115
- name: "maxOi",
1116
- type: "uint72",
1117
- },
1118
- {
1119
- internalType: "uint48",
1120
- name: "feeExponent",
1121
- type: "uint48",
1122
- },
1123
- {
1124
- internalType: "uint128",
1125
- name: "collateralPrecision",
1126
- type: "uint128",
1127
- },
1128
- ],
1129
- internalType: "struct IGNSBorrowingFees.PendingAccFeesInput",
1130
- name: "input",
1131
- type: "tuple",
1132
- },
1133
- ],
1134
- name: "getPendingAccFees",
1135
- outputs: [
1136
- {
1137
- internalType: "uint64",
1138
- name: "newAccFeeLong",
1139
- type: "uint64",
1140
- },
1141
- {
1142
- internalType: "uint64",
1143
- name: "newAccFeeShort",
1144
- type: "uint64",
1145
- },
1146
- {
1147
- internalType: "uint64",
1148
- name: "delta",
1149
- type: "uint64",
1150
- },
1151
- ],
1152
- stateMutability: "pure",
1153
- type: "function",
1154
- },
1155
- {
1156
- inputs: [
1157
- {
1158
- components: [
1159
- {
1160
- internalType: "address",
1161
- name: "trader",
1162
- type: "address",
1163
- },
1164
- {
1165
- internalType: "uint256",
1166
- name: "pairIndex",
1167
- type: "uint256",
1168
- },
1169
- {
1170
- internalType: "uint256",
1171
- name: "index",
1172
- type: "uint256",
1173
- },
1174
- {
1175
- internalType: "bool",
1176
- name: "long",
1177
- type: "bool",
1178
- },
1179
- {
1180
- internalType: "uint256",
1181
- name: "collateral",
1182
- type: "uint256",
1183
- },
1184
- {
1185
- internalType: "uint256",
1186
- name: "leverage",
1187
- type: "uint256",
1188
- },
1189
- ],
1190
- internalType: "struct IGNSBorrowingFees.BorrowingFeeInput",
1191
- name: "input",
1192
- type: "tuple",
1193
- },
1194
- ],
1195
- name: "getTradeBorrowingFee",
1196
- outputs: [
1197
- {
1198
- internalType: "uint256",
1199
- name: "fee",
1200
- type: "uint256",
1201
- },
1202
- ],
1203
- stateMutability: "view",
1204
- type: "function",
1205
- },
1206
- {
1207
- inputs: [
1208
- {
1209
- components: [
1210
- {
1211
- internalType: "address",
1212
- name: "trader",
1213
- type: "address",
1214
- },
1215
- {
1216
- internalType: "uint256",
1217
- name: "pairIndex",
1218
- type: "uint256",
1219
- },
1220
- {
1221
- internalType: "uint256",
1222
- name: "index",
1223
- type: "uint256",
1224
- },
1225
- {
1226
- internalType: "uint256",
1227
- name: "openPrice",
1228
- type: "uint256",
1229
- },
1230
- {
1231
- internalType: "bool",
1232
- name: "long",
1233
- type: "bool",
1234
- },
1235
- {
1236
- internalType: "uint256",
1237
- name: "collateral",
1238
- type: "uint256",
1239
- },
1240
- {
1241
- internalType: "uint256",
1242
- name: "leverage",
1243
- type: "uint256",
1244
- },
1245
- ],
1246
- internalType: "struct IGNSBorrowingFees.LiqPriceInput",
1247
- name: "input",
1248
- type: "tuple",
1249
- },
1250
- ],
1251
- name: "getTradeLiquidationPrice",
1252
- outputs: [
1253
- {
1254
- internalType: "uint256",
1255
- name: "",
1256
- type: "uint256",
1257
- },
1258
- ],
1259
- stateMutability: "view",
1260
- type: "function",
1261
- },
1262
- {
1263
- inputs: [
1264
- {
1265
- internalType: "uint256",
1266
- name: "",
1267
- type: "uint256",
1268
- },
1269
- ],
1270
- name: "groupFeeExponents",
1271
- outputs: [
1272
- {
1273
- internalType: "uint48",
1274
- name: "",
1275
- type: "uint48",
1276
- },
1277
- ],
1278
- stateMutability: "view",
1279
- type: "function",
1280
- },
1281
- {
1282
- inputs: [
1283
- {
1284
- internalType: "uint16",
1285
- name: "",
1286
- type: "uint16",
1287
- },
1288
- ],
1289
- name: "groups",
1290
- outputs: [
1291
- {
1292
- internalType: "uint112",
1293
- name: "oiLong",
1294
- type: "uint112",
1295
- },
1296
- {
1297
- internalType: "uint112",
1298
- name: "oiShort",
1299
- type: "uint112",
1300
- },
1301
- {
1302
- internalType: "uint32",
1303
- name: "feePerBlock",
1304
- type: "uint32",
1305
- },
1306
- {
1307
- internalType: "uint64",
1308
- name: "accFeeLong",
1309
- type: "uint64",
1310
- },
1311
- {
1312
- internalType: "uint64",
1313
- name: "accFeeShort",
1314
- type: "uint64",
1315
- },
1316
- {
1317
- internalType: "uint48",
1318
- name: "accLastUpdatedBlock",
1319
- type: "uint48",
1320
- },
1321
- {
1322
- internalType: "uint80",
1323
- name: "maxOi",
1324
- type: "uint80",
1325
- },
1326
- {
1327
- internalType: "uint256",
1328
- name: "lastAccBlockWeightedMarketCap",
1329
- type: "uint256",
1330
- },
1331
- ],
1332
- stateMutability: "view",
1333
- type: "function",
1334
- },
1335
- {
1336
- inputs: [
1337
- {
1338
- internalType: "address",
1339
- name: "trader",
1340
- type: "address",
1341
- },
1342
- {
1343
- internalType: "uint256",
1344
- name: "pairIndex",
1345
- type: "uint256",
1346
- },
1347
- {
1348
- internalType: "uint256",
1349
- name: "index",
1350
- type: "uint256",
1351
- },
1352
- {
1353
- internalType: "uint256",
1354
- name: "positionSizeDai",
1355
- type: "uint256",
1356
- },
1357
- {
1358
- internalType: "bool",
1359
- name: "open",
1360
- type: "bool",
1361
- },
1362
- {
1363
- internalType: "bool",
1364
- name: "long",
1365
- type: "bool",
1366
- },
1367
- ],
1368
- name: "handleTradeAction",
1369
- outputs: [],
1370
- stateMutability: "nonpayable",
1371
- type: "function",
1372
- },
1373
- {
1374
- inputs: [
1375
- {
1376
- internalType: "address",
1377
- name: "",
1378
- type: "address",
1379
- },
1380
- {
1381
- internalType: "uint256",
1382
- name: "",
1383
- type: "uint256",
1384
- },
1385
- {
1386
- internalType: "uint256",
1387
- name: "",
1388
- type: "uint256",
1389
- },
1390
- ],
1391
- name: "initialAccFees",
1392
- outputs: [
1393
- {
1394
- internalType: "uint64",
1395
- name: "accPairFee",
1396
- type: "uint64",
1397
- },
1398
- {
1399
- internalType: "uint64",
1400
- name: "accGroupFee",
1401
- type: "uint64",
1402
- },
1403
- {
1404
- internalType: "uint48",
1405
- name: "block",
1406
- type: "uint48",
1407
- },
1408
- {
1409
- internalType: "uint80",
1410
- name: "_placeholder",
1411
- type: "uint80",
1412
- },
1413
- ],
1414
- stateMutability: "view",
1415
- type: "function",
1416
- },
1417
- {
1418
- inputs: [
1419
- {
1420
- internalType: "contract IGNSTradingStorage",
1421
- name: "_storageT",
1422
- type: "address",
1423
- },
1424
- ],
1425
- name: "initialize",
1426
- outputs: [],
1427
- stateMutability: "nonpayable",
1428
- type: "function",
1429
- },
1430
- {
1431
- inputs: [
1432
- {
1433
- internalType: "contract IGNSMultiCollatDiamond",
1434
- name: "_multiCollatDiamond",
1435
- type: "address",
1436
- },
1437
- ],
1438
- name: "initializeV3",
1439
- outputs: [],
1440
- stateMutability: "nonpayable",
1441
- type: "function",
1442
- },
1443
- {
1444
- inputs: [],
1445
- name: "multiCollatDiamond",
1446
- outputs: [
1447
- {
1448
- internalType: "contract IGNSMultiCollatDiamond",
1449
- name: "",
1450
- type: "address",
1451
- },
1452
- ],
1453
- stateMutability: "view",
1454
- type: "function",
1455
- },
1456
- {
1457
- inputs: [],
1458
- name: "pairInfos",
1459
- outputs: [
1460
- {
1461
- internalType: "address",
1462
- name: "",
1463
- type: "address",
1464
- },
1465
- ],
1466
- stateMutability: "view",
1467
- type: "function",
1468
- },
1469
- {
1470
- inputs: [
1471
- {
1472
- internalType: "uint256",
1473
- name: "",
1474
- type: "uint256",
1475
- },
1476
- ],
1477
- name: "pairOis",
1478
- outputs: [
1479
- {
1480
- internalType: "uint72",
1481
- name: "long",
1482
- type: "uint72",
1483
- },
1484
- {
1485
- internalType: "uint72",
1486
- name: "short",
1487
- type: "uint72",
1488
- },
1489
- {
1490
- internalType: "uint72",
1491
- name: "max",
1492
- type: "uint72",
1493
- },
1494
- {
1495
- internalType: "uint40",
1496
- name: "_placeholder",
1497
- type: "uint40",
1498
- },
1499
- ],
1500
- stateMutability: "view",
1501
- type: "function",
1502
- },
1503
- {
1504
- inputs: [
1505
- {
1506
- internalType: "uint256",
1507
- name: "",
1508
- type: "uint256",
1509
- },
1510
- ],
1511
- name: "pairs",
1512
- outputs: [
1513
- {
1514
- internalType: "uint32",
1515
- name: "feePerBlock",
1516
- type: "uint32",
1517
- },
1518
- {
1519
- internalType: "uint64",
1520
- name: "accFeeLong",
1521
- type: "uint64",
1522
- },
1523
- {
1524
- internalType: "uint64",
1525
- name: "accFeeShort",
1526
- type: "uint64",
1527
- },
1528
- {
1529
- internalType: "uint48",
1530
- name: "accLastUpdatedBlock",
1531
- type: "uint48",
1532
- },
1533
- {
1534
- internalType: "uint48",
1535
- name: "feeExponent",
1536
- type: "uint48",
1537
- },
1538
- {
1539
- internalType: "uint256",
1540
- name: "lastAccBlockWeightedMarketCap",
1541
- type: "uint256",
1542
- },
1543
- ],
1544
- stateMutability: "view",
1545
- type: "function",
1546
- },
1547
- {
1548
- inputs: [
1549
- {
1550
- internalType: "uint16",
1551
- name: "groupIndex",
1552
- type: "uint16",
1553
- },
1554
- {
1555
- components: [
1556
- {
1557
- internalType: "uint32",
1558
- name: "feePerBlock",
1559
- type: "uint32",
1560
- },
1561
- {
1562
- internalType: "uint72",
1563
- name: "maxOi",
1564
- type: "uint72",
1565
- },
1566
- {
1567
- internalType: "uint48",
1568
- name: "feeExponent",
1569
- type: "uint48",
1570
- },
1571
- ],
1572
- internalType: "struct IGNSBorrowingFees.GroupParams",
1573
- name: "value",
1574
- type: "tuple",
1575
- },
1576
- ],
1577
- name: "setGroupParams",
1578
- outputs: [],
1579
- stateMutability: "nonpayable",
1580
- type: "function",
1581
- },
1582
- {
1583
- inputs: [
1584
- {
1585
- internalType: "uint16[]",
1586
- name: "indices",
1587
- type: "uint16[]",
1588
- },
1589
- {
1590
- components: [
1591
- {
1592
- internalType: "uint32",
1593
- name: "feePerBlock",
1594
- type: "uint32",
1595
- },
1596
- {
1597
- internalType: "uint72",
1598
- name: "maxOi",
1599
- type: "uint72",
1600
- },
1601
- {
1602
- internalType: "uint48",
1603
- name: "feeExponent",
1604
- type: "uint48",
1605
- },
1606
- ],
1607
- internalType: "struct IGNSBorrowingFees.GroupParams[]",
1608
- name: "values",
1609
- type: "tuple[]",
1610
- },
1611
- ],
1612
- name: "setGroupParamsArray",
1613
- outputs: [],
1614
- stateMutability: "nonpayable",
1615
- type: "function",
1616
- },
1617
- {
1618
- inputs: [
1619
- {
1620
- internalType: "uint256",
1621
- name: "pairIndex",
1622
- type: "uint256",
1623
- },
1624
- {
1625
- components: [
1626
- {
1627
- internalType: "uint16",
1628
- name: "groupIndex",
1629
- type: "uint16",
1630
- },
1631
- {
1632
- internalType: "uint32",
1633
- name: "feePerBlock",
1634
- type: "uint32",
1635
- },
1636
- {
1637
- internalType: "uint48",
1638
- name: "feeExponent",
1639
- type: "uint48",
1640
- },
1641
- {
1642
- internalType: "uint72",
1643
- name: "maxOi",
1644
- type: "uint72",
1645
- },
1646
- ],
1647
- internalType: "struct IGNSBorrowingFees.PairParams",
1648
- name: "value",
1649
- type: "tuple",
1650
- },
1651
- ],
1652
- name: "setPairParams",
1653
- outputs: [],
1654
- stateMutability: "nonpayable",
1655
- type: "function",
1656
- },
1657
- {
1658
- inputs: [
1659
- {
1660
- internalType: "uint256[]",
1661
- name: "indices",
1662
- type: "uint256[]",
1663
- },
1664
- {
1665
- components: [
1666
- {
1667
- internalType: "uint16",
1668
- name: "groupIndex",
1669
- type: "uint16",
1670
- },
1671
- {
1672
- internalType: "uint32",
1673
- name: "feePerBlock",
1674
- type: "uint32",
1675
- },
1676
- {
1677
- internalType: "uint48",
1678
- name: "feeExponent",
1679
- type: "uint48",
1680
- },
1681
- {
1682
- internalType: "uint72",
1683
- name: "maxOi",
1684
- type: "uint72",
1685
- },
1686
- ],
1687
- internalType: "struct IGNSBorrowingFees.PairParams[]",
1688
- name: "values",
1689
- type: "tuple[]",
1690
- },
1691
- ],
1692
- name: "setPairParamsArray",
1693
- outputs: [],
1694
- stateMutability: "nonpayable",
1695
- type: "function",
1696
- },
1697
- {
1698
- inputs: [],
1699
- name: "storageT",
1700
- outputs: [
1701
- {
1702
- internalType: "contract IGNSTradingStorage",
1703
- name: "",
1704
- type: "address",
1705
- },
1706
- ],
1707
- stateMutability: "view",
1708
- type: "function",
1709
- },
1710
- {
1711
- inputs: [
1712
- {
1713
- internalType: "uint256",
1714
- name: "pairIndex",
1715
- type: "uint256",
1716
- },
1717
- {
1718
- internalType: "bool",
1719
- name: "long",
1720
- type: "bool",
1721
- },
1722
- {
1723
- internalType: "uint256",
1724
- name: "positionSizeDai",
1725
- type: "uint256",
1726
- },
1727
- ],
1728
- name: "withinMaxGroupOi",
1729
- outputs: [
1730
- {
1731
- internalType: "bool",
1732
- name: "",
1733
- type: "bool",
1734
- },
1735
- ],
1736
- stateMutability: "view",
1737
- type: "function",
1738
- },
1739
- ];
1740
- const _bytecode = "0x608060405234801561001057600080fd5b50614833806100206000396000f3fe608060405234801561001057600080fd5b50600436106101cb5760003560e01c80638f6942381161010a578063bcb78871116100ad578063ce67edfb1161007c578063ce67edfb1461079b578063d6274505146107ae578063e3e98a75146107d1578063f800ece914610810578063ff933fc41461082657600080fd5b8063bcb7887114610741578063bdf391cc14610754578063c39e1a8b14610775578063c4d66de81461078857600080fd5b80638f694238146104cf57806390895ff1146104f5578063930842aa1461059e578063b0baf5d4146105b1578063b2c9dd8b146105c4578063b91ac788146105d7578063b94ffa1c1461068d578063bb219c75146106bd57600080fd5b8063358129601161017257806335812960146102e95780633979324d146102fc5780634c67cfa0146103f35780635c0ab4de1461041b578063651501b514610459578063706faf3a1461046c5780637b64112b1461047f5780638ee1caa71461049257600080fd5b80630a6c9b3b146101d05780630f8df7e0146101f65780631346b0ff1461023157806316fff0741461025c5780631ab5911a1461027557806322005202146102a05780632d28a817146102c15780633101cfcb146102d4575b600080fd5b6101e36101de366004613791565b610847565b6040519081526020015b60405180910390f35b610209610204366004613937565b610894565b604080516001600160401b0394851681529390921660208401521515908201526060016101ed565b600154610244906001600160a01b031681565b6040516001600160a01b0390911681526020016101ed565b600054610244906201000090046001600160a01b031681565b610288610283366004613ac7565b610a14565b6040516001600160401b0390911681526020016101ed565b6102b36102ae366004613b4b565b610a41565b6040516101ed929190613c12565b6101e36102cf366004613cb5565b610c6d565b6102e76102e2366004613d3f565b610f87565b005b600a54610244906001600160a01b031681565b61038861030a366004613d5c565b60026020819052600091825260409091208054600182015491909201546001600160701b0380841693600160701b810490911692600160e01b90910463ffffffff16916001600160401b0380831692600160401b810490911691600160801b820465ffffffffffff1691600160b01b90046001600160501b03169088565b604080516001600160701b03998a16815298909716602089015263ffffffff909516958701959095526001600160401b0392831660608701529116608085015265ffffffffffff1660a08401526001600160501b0390911660c083015260e0820152610100016101ed565b610406610401366004613791565b611113565b604080519283526020830191909152016101ed565b600954610439906001600160801b0380821691600160801b90041682565b604080516001600160801b039384168152929091166020830152016101ed565b6102e7610467366004613d77565b611210565b6101e361047a366004613e10565b611316565b61028861048d366004613e28565b61143c565b6104a56104a0366004613e56565b611447565b604080516001600160401b03948516815292841660208401529216918101919091526060016101ed565b6104e26104dd366004613791565b611674565b60405161ffff90911681526020016101ed565b61055d610503366004613e78565b60046020908152600093845260408085208252928452828420905282529020546001600160401b0380821691600160401b810490911690600160801b810465ffffffffffff1690600160b01b90046001600160501b031684565b604080516001600160401b03958616815294909316602085015265ffffffffffff909116918301919091526001600160501b031660608201526080016101ed565b6102e76105ac366004613ead565b611796565b6102e76105bf366004613eec565b611835565b6102e76105d2366004613f16565b6118d0565b6106416105e5366004613791565b6003602052600090815260409020600181015460029091015463ffffffff8216916001600160401b03600160201b8204811692600160601b83049091169165ffffffffffff600160a01b8204811692600160d01b909204169086565b6040805163ffffffff9790971687526001600160401b039586166020880152939094169285019290925265ffffffffffff908116606085015216608083015260a082015260c0016101ed565b6101e361069b366004613791565b600090815260056020526040902054600160901b90046001600160481b031690565b61070a6106cb366004613791565b6005602052600090815260409020546001600160481b0380821691600160481b8104821691600160901b82041690600160d81b900464ffffffffff1684565b604080516001600160481b0395861681529385166020850152919093169082015264ffffffffff90911660608201526080016101ed565b6104a561074f366004613fa0565b6119dc565b610767610762366004613791565b611b97565b6040516101ed92919061413d565b6104a56107833660046141a1565b611d84565b6102e7610796366004613d3f565b611e0e565b6102e76107a936600461424d565b611f12565b6107c16107bc3660046142b4565b612244565b60405190151581526020016101ed565b6107f96107df366004613791565b60066020526000908152604090205465ffffffffffff1681565b60405165ffffffffffff90911681526020016101ed565b610818612370565b6040516101ed9291906142ec565b610839610834366004613d5c565b6126c0565b6040516101ed929190614391565b6000818152600560205260408120546009546402540be4009161088491600160901b9091046001600160481b0316906001600160801b03166143cc565b61088e91906143e3565b92915050565b600080600080888a815181106108ac576108ac614405565b60200260200101519050876040015165ffffffffffff16816020015165ffffffffffff16109150600189516108e1919061441b565b8a036109085780516108f4908688610a14565b935061090187868861143c565b9250610998565b6000896109168c600161442e565b8151811061092657610926614405565b602002602001015190508280156109555750886040015165ffffffffffff16816020015165ffffffffffff1611155b1561096857600080945094505050610a08565b86610977578060a0015161097d565b80608001515b94508661098e578060e00151610994565b8060c001515b9350505b81156109c35760208801516109ad9085614441565b88519094506109bc9084614441565b9250610a06565b856109d25780606001516109d8565b80604001515b6109e29085614441565b9350856109f3578060e001516109f9565b8060c001515b610a039084614441565b92505b505b96509650969350505050565b6000806000610a2386866119dc565b509150915083610a335780610a35565b815b925050505b9392505050565b6060806000836001600160401b03811115610a5e57610a5e6137aa565b604051908082528060200260200182016040528015610a9757816020015b610a84613711565b815260200190600190039081610a7c5790505b5090506000846001600160401b03811115610ab457610ab46137aa565b604051908082528060200260200182016040528015610add578160200160208202803683370190505b5090508460005b81811015610c5e5760026000898984818110610b0257610b02614405565b9050602002016020810190610b179190613d5c565b61ffff168152602080820192909252604090810160002081516101008101835281546001600160701b038082168352600160701b82041694820194909452600160e01b90930463ffffffff169183019190915260018101546001600160401b038082166060850152600160401b8204166080840152600160801b810465ffffffffffff1660a0840152600160b01b90046001600160501b031660c08301526002015460e08201528451859083908110610bd257610bd2614405565b602002602001018190525060066000898984818110610bf357610bf3614405565b9050602002016020810190610c089190613d5c565b61ffff16815260200190815260200160002060009054906101000a900465ffffffffffff16838281518110610c3f57610c3f614405565b65ffffffffffff90921660209283029190910190910152600101610ae4565b509193509150505b9250929050565b80516001600160a01b03166000908152600460209081526040808320828501805185529083528184208286015185528352818420825160808101845290546001600160401b038082168352600160401b82041682860152600160801b810465ffffffffffff1682850152600160b01b90046001600160501b0316606082015290518452600383528184208054835181860281018601909452808452919385939290849084015b82821015610dc4576000848152602090819020604080516101208101825260028602909201805461ffff8116845265ffffffffffff62010000820416848601526001600160401b03600160401b808304821694860194909452600160801b80830482166060870152600160c01b928390048216608087015260019384015480831660a0880152948504821660c08701528404811660e086015292049091166101008301529083529092019101610d13565b5050505090506000610dd4612780565b6040805161012081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810191909152909150825115610e455782600081518110610e3a57610e3a614405565b602002602001015190505b82511580610e6a5750836040015165ffffffffffff16816020015165ffffffffffff16115b15610ebe578351835115610e95578660600151610e8b578160e00151610ea8565b8160c00151610ea8565b610ea8876020015184896060015161143c565b610eb29190614441565b6001600160401b031694505b82515b8015610f415760008080610eeb610ed960018661441b565b888a8d602001518e606001518b610894565b925092509250816001600160401b0316836001600160401b031611610f105781610f12565b825b610f25906001600160401b03168a61442e565b98508015610f3557505050610f41565b50505060001901610ec1565b5060646402540be400868860a001518960800151610f5f91906143cc565b610f6991906143cc565b610f7391906143e3565b610f7d91906143e3565b9695505050505050565b600054600390610100900460ff16158015610fa9575060005460ff8083169116105b610fce5760405162461bcd60e51b8152600401610fc590614468565b60405180910390fd5b6000805461ffff191660ff8316176101001790556001600160a01b03821661100957604051635863f78960e01b815260040160405180910390fd5b600180546001600160a01b03191690556000546040805163f4b9fa7560e01b81529051611093926201000090046001600160a01b03169163f4b9fa759160048083019260209291908290030181865afa15801561106a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061108e91906144b6565b612806565b80516020918201516001600160801b03908116600160801b02911617600955600a80546001600160a01b0385166001600160a01b03199091161790556000805461ff001916905560405160ff831681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb384740249891015b60405180910390a15050565b600080546040516328daca2160e01b8152600481018490526024810183905282916201000090046001600160a01b0316906328daca2190604401602060405180830381865afa15801561116a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061118e91906144d3565b6000546040516328daca2160e01b81526004810186905260016024820152620100009091046001600160a01b0316906328daca2190604401602060405180830381865afa1580156111e3573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061120791906144d3565b91509150915091565b600a546040516395a8c58d60e01b81526001600160a01b03909116906395a8c58d906112439033906005906004016144ec565b602060405180830381865afa158015611260573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112849190614527565b6112a157604051631b17ff5560e21b815260040160405180910390fd5b828181146112c2576040516349552d5960e11b815260040160405180910390fd5b60005b8181101561130e576113068686838181106112e2576112e2614405565b905060200201358585848181106112fb576112fb614405565b9050608002016128c3565b6001016112c5565b505050505050565b600073__$80699a18f5fb835ede6cb415cbdea2f026$__63a80896d2606084013561134760a0860160808701614544565b8560a001358660c001356113c26040518060c001604052808a60000160208101906113729190613d3f565b6001600160a01b0316815260208b810135908201526040808c0135908201526060016113a460a08c0160808d01614544565b151581526020018a60a0013581526020018a60c00135815250610c6d565b6040516001600160e01b031960e088901b1681526004810195909552921515602485015260448401919091526064830152608482015260a401602060405180830381865af4158015611418573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061088e91906144d3565b6000806000610a2386865b6000828152600360209081526040808320815181546101009481028201850190935260e0810183815285948594859492849290918491879085015b82821015611533576000848152602090819020604080516101208101825260028602909201805461ffff8116845265ffffffffffff62010000820416848601526001600160401b03600160401b808304821694860194909452600160801b80830482166060870152600160c01b928390048216608087015260019384015480831660a0880152948504821660c08701528404811660e086015292049091166101008301529083529092019101611482565b50505090825250600182015463ffffffff811660208301526001600160401b03600160201b820481166040840152600160601b820416606083015265ffffffffffff600160a01b820481166080840152600160d01b9091041660a082015260029091015460c09091015290506000806115ab88611113565b6040805161014081018252868201516001600160401b0390811682526060808901519091166020808401919091528284018690529082018490528088015163ffffffff1660808084019190915260a08084018e90529089015165ffffffffffff90811660c085015260008f815260059093529390912054600160901b90046001600160481b031660e08301528701519091166101008201526009546001600160801b0316610120820152919350915061166390611d84565b919a90995090975095505050505050565b600081815260036020908152604080832080548251818502810185019093528083528493849084015b8282101561174e576000848152602090819020604080516101208101825260028602909201805461ffff8116845265ffffffffffff62010000820416848601526001600160401b03600160401b808304821694860194909452600160801b80830482166060870152600160c01b928390048216608087015260019384015480831660a0880152948504821660c08701528404811660e08601529204909116610100830152908352909201910161169d565b505050509050805160001461178d57806001825161176c919061441b565b8151811061177c5761177c614405565b602002602001015160000151610a3a565b60009392505050565b600a546040516395a8c58d60e01b81526001600160a01b03909116906395a8c58d906117c99033906005906004016144ec565b602060405180830381865afa1580156117e6573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061180a9190614527565b61182757604051631b17ff5560e21b815260040160405180910390fd5b6118318282613117565b5050565b600a546040516395a8c58d60e01b81526001600160a01b03909116906395a8c58d906118689033906005906004016144ec565b602060405180830381865afa158015611885573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906118a99190614527565b6118c657604051631b17ff5560e21b815260040160405180910390fd5b61183182826128c3565b600a546040516395a8c58d60e01b81526001600160a01b03909116906395a8c58d906119039033906005906004016144ec565b602060405180830381865afa158015611920573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906119449190614527565b61196157604051631b17ff5560e21b815260040160405180910390fd5b82818114611982576040516349552d5960e11b815260040160405180910390fd5b60005b8181101561130e576119d48686838181106119a2576119a2614405565b90506020020160208101906119b79190613d5c565b8585848181106119c9576119c9614405565b905060600201613117565b600101611985565b61ffff8216600090815260026020818152604080842081516101008101835281546001600160701b038082168352600160701b8204811683870152600160e01b90910463ffffffff168285015260018301546001600160401b0380821660608501908152600160401b8304821660808601908152600160801b840465ffffffffffff1660a0870152600160b01b9093046001600160501b031660c0860152949097015460e084015260095485516101408101875294518816855290519096169483019490945280518695869592946001600160801b0390911693611b87939092918301916402540be40091611ad3918791166143cc565b611add91906143e3565b81526020016402540be400846001600160801b031686602001516001600160701b0316611b0a91906143cc565b611b1491906143e3565b815260408086015163ffffffff166020808401919091528183018b905260a08088015165ffffffffffff908116606086015260c0808a01516001600160481b0316608087015261ffff8f16600090815260069094529390922054909116908301526001600160801b038516910152611d84565b9199909850909650945050505050565b611b9f613755565b6040805160808101825260008082526020808301829052828401829052606083018290528582526003815283822060058252848320855182546101009481028201850190975260e0810187815295969295919490938693859392859285015b82821015611caf576000848152602090819020604080516101208101825260028602909201805461ffff8116845265ffffffffffff62010000820416848601526001600160401b03600160401b808304821694860194909452600160801b80830482166060870152600160c01b928390048216608087015260019384015480831660a0880152948504821660c08701528404811660e086015292049091166101008301529083529092019101611bfe565b50505090825250600182015463ffffffff8116602080840191909152600160201b82046001600160401b03908116604080860191909152600160601b8404909116606080860191909152600160a01b840465ffffffffffff908116608080880191909152600160d01b9095041660a086015260029095015460c0909401939093528251918201835294546001600160481b038082168352600160481b8204811696830196909652600160901b810490951691810191909152600160d81b90930464ffffffffff16908301529590945092505050565b600080600073__$80699a18f5fb835ede6cb415cbdea2f026$__63229745ad856040518263ffffffff1660e01b8152600401611dc09190614561565b606060405180830381865af4158015611ddd573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611e019190614617565b9250925092509193909250565b600054610100900460ff1615808015611e2e5750600054600160ff909116105b80611e485750303b158015611e48575060005460ff166001145b611e645760405162461bcd60e51b8152600401610fc590614468565b6000805460ff191660011790558015611e87576000805461ff0019166101001790555b6001600160a01b038216611eae57604051635863f78960e01b815260040160405180910390fd5b6000805462010000600160b01b031916620100006001600160a01b038516021790558015611831576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb384740249890602001611107565b600060029054906101000a90046001600160a01b03166001600160a01b031662b127836040518163ffffffff1660e01b8152600401602060405180830381865afa158015611f64573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611f8891906144b6565b6001600160a01b0316336001600160a01b031614611fb957604051631b17ff5560e21b815260040160405180910390fd5b6000611fc486611674565b90506000611fd0612780565b9050600080611fdf89846132ef565b91509150600080611ff086866133f3565b9150915061200086888a8c6134e0565b87156121d657600060405180608001604052808961201e5785612020565b865b6001600160401b0316815260200189612039578361203b565b845b6001600160401b03168152602001612052886136e4565b65ffffffffffff16815260200160006001600160501b0316815250905080600460008f6001600160a01b03166001600160a01b0316815260200190815260200160002060008e815260200190815260200160002060008d815260200190815260200160002060008201518160000160006101000a8154816001600160401b0302191690836001600160401b0316021790555060208201518160000160086101000a8154816001600160401b0302191690836001600160401b0316021790555060408201518160000160106101000a81548165ffffffffffff021916908365ffffffffffff16021790555060608201518160000160166101000a8154816001600160501b0302191690836001600160501b031602179055509050508b8d6001600160a01b03167faa00ca5c6f282cb9f35953ecb0eaf8e39c95b7c8df114efac12162a85c085e608d846000015185602001516040516121cc939291909283526001600160401b03918216602084015216604082015260600190565b60405180910390a3505b8a8c6001600160a01b03167f66baa1848f5d4d14567e9bc527e5608778c86e512490d413cfafc9250327308f8c8b8b8e60405161222e9493929190938452911515602084015215156040830152606082015260800190565b60405180910390a3505050505050505050505050565b6000806002600061225487611674565b61ffff168152602080820192909252604090810160002081516101008101835281546001600160701b038082168352600160701b82041694820194909452600160e01b90930463ffffffff169183019190915260018101546001600160401b038082166060850152600160401b8204166080840152600160801b810465ffffffffffff1660a0840152600160b01b90046001600160501b031660c0830181905260029091015460e08301529091501580612367575060c08101516009546001600160501b03909116906001600160801b03166123356402540be400866143cc565b61233f91906143e3565b8561234e578260200151612351565b82515b6001600160701b0316612364919061442e565b11155b95945050505050565b6060806000600a60009054906101000a90046001600160a01b03166001600160a01b031663b81b2b716040518163ffffffff1660e01b8152600401602060405180830381865afa1580156123c8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906123ec91906144d3565b90506000816001600160401b03811115612408576124086137aa565b60405190808252806020026020018201604052801561244157816020015b61242e613755565b8152602001906001900390816124265790505b5090506000826001600160401b0381111561245e5761245e6137aa565b6040519080825280602002602001820160405280156124b057816020015b60408051608081018252600080825260208083018290529282018190526060820152825260001990920191018161247c5790505b50905060005b838110156126b5576000818152600360209081526040808320815181546101009481028201850190935260e08101838152909491938593919285929185015b828210156125a6576000848152602090819020604080516101208101825260028602909201805461ffff8116845265ffffffffffff62010000820416848601526001600160401b03600160401b808304821694860194909452600160801b80830482166060870152600160c01b928390048216608087015260019384015480831660a0880152948504821660c08701528404811660e0860152920490911661010083015290835290920191016124f5565b50505090825250600182015463ffffffff811660208301526001600160401b03600160201b820481166040840152600160601b820416606083015265ffffffffffff600160a01b820481166080840152600160d01b9091041660a082015260029091015460c090910152835184908390811061262457612624614405565b602090810291909101810191909152600082815260058252604090819020815160808101835290546001600160481b038082168352600160481b8204811694830194909452600160901b810490931691810191909152600160d81b90910464ffffffffff16606082015282518390839081106126a2576126a2614405565b60209081029190910101526001016124b6565b509094909350915050565b6126c8613711565b5061ffff16600090815260026020818152604080842060068352938190205481516101008101835285546001600160701b038082168352600160701b82041694820194909452600160e01b90930463ffffffff169183019190915260018401546001600160401b038082166060850152600160401b820416608084015265ffffffffffff600160801b8204811660a0850152600160b01b9091046001600160501b031660c0840152939092015460e082015292911690565b600061a4b1461480612794575062066eee46145b156128015760646001600160a01b031663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156127d8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906127fc91906144d3565b905090565b504390565b60408051808201909152600080825260208201526000826001600160a01b031663313ce5676040518163ffffffff1660e01b8152600401602060405180830381865afa15801561285a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061287e9190614659565b60ff16905061288e81600a614760565b6001600160801b031682526128a481601261441b565b6128af90600a614760565b6001600160801b0316602083015250919050565b60016128d5606083016040840161476c565b65ffffffffffff161080612900575060036128f6606083016040840161476c565b65ffffffffffff16115b1561291e57604051633951a25360e01b815260040160405180910390fd5b60008281526003602052604081209061293684611674565b90506000612942612780565b905061294e85826132ef565b505061ffff82166129626020860186613d5c565b61ffff1614612fc85761297582826133f3565b5061298e90506129886020860186613d5c565b826133f3565b505060008061299c87611113565b915091506129ae8460016000856134e0565b6129bb84600080846134e0565b6129d46129cb6020880188613d5c565b600180856134e0565b6129ee6129e46020880188613d5c565b60006001846134e0565b6000600281612a0060208a018a613d5c565b61ffff1661ffff168152602001908152602001600020604051806101000160405290816000820160009054906101000a90046001600160701b03166001600160701b03166001600160701b0316815260200160008201600e9054906101000a90046001600160701b03166001600160701b03166001600160701b0316815260200160008201601c9054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016001820160009054906101000a90046001600160401b03166001600160401b03166001600160401b031681526020016001820160089054906101000a90046001600160401b03166001600160401b03166001600160401b031681526020016001820160109054906101000a900465ffffffffffff1665ffffffffffff1665ffffffffffff1681526020016001820160169054906101000a90046001600160501b03166001600160501b03166001600160501b0316815260200160028201548152505090506000600260008761ffff1661ffff168152602001908152602001600020604051806101000160405290816000820160009054906101000a90046001600160701b03166001600160701b03166001600160701b0316815260200160008201600e9054906101000a90046001600160701b03166001600160701b03166001600160701b0316815260200160008201601c9054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016001820160009054906101000a90046001600160401b03166001600160401b03166001600160401b031681526020016001820160089054906101000a90046001600160401b03166001600160401b03166001600160401b031681526020016001820160109054906101000a900465ffffffffffff1665ffffffffffff1665ffffffffffff1681526020016001820160169054906101000a90046001600160501b03166001600160501b03166001600160501b031681526020016002820154815250509050866000016040518061012001604052808a6000016020810190612d009190613d5c565b61ffff168152602001612d12886136e4565b65ffffffffffff16815260200184606001516001600160401b0316815260200184608001516001600160401b0316815260200183606001516001600160401b0316815260200183608001516001600160401b031681526020018960010160049054906101000a90046001600160401b03166001600160401b0316815260200189600101600c9054906101000a90046001600160401b03166001600160401b0316815260200160006001600160401b0316815250908060018154018082558091505060019003906000526020600020906002020160009091909190915060008201518160000160006101000a81548161ffff021916908361ffff16021790555060208201518160000160026101000a81548165ffffffffffff021916908365ffffffffffff16021790555060408201518160000160086101000a8154816001600160401b0302191690836001600160401b0316021790555060608201518160000160106101000a8154816001600160401b0302191690836001600160401b0316021790555060808201518160000160186101000a8154816001600160401b0302191690836001600160401b0316021790555060a08201518160010160006101000a8154816001600160401b0302191690836001600160401b0316021790555060c08201518160010160086101000a8154816001600160401b0302191690836001600160401b0316021790555060e08201518160010160106101000a8154816001600160401b0302191690836001600160401b031602179055506101008201518160010160186101000a8154816001600160401b0302191690836001600160401b031602179055505050876000016020810190612f8d9190613d5c565b61ffff168661ffff168a7f5beb7d73e1c3cd532d47c9e896931df26d9be450a833bd5fe1ace6bf5690d46860405160405180910390a4505050505b612fd86040850160208601614787565b60018401805463ffffffff191663ffffffff92909216919091179055613004606085016040860161476c565b60018401805465ffffffffffff92909216600160d01b026001600160d01b0390921691909117905561303c60808501606086016147a2565b600086815260056020908152604090912080546001600160481b0393909316600160901b0268ffffffffffffffffff60901b199093169290921790915561308590850185613d5c565b61ffff16857f1caa8de744ea74fb9e0c2f32b7fed3b30ea426105a6b73926010be6372458ef46130bb6040880160208901614787565b6130cb6060890160408a0161476c565b6130db60808a0160608b016147a2565b6040805163ffffffff909416845265ffffffffffff90921660208401526001600160481b03169082015260600160405180910390a35050505050565b8161ffff1660000361313c57604051630d24975d60e21b815260040160405180910390fd5b600161314e606083016040840161476c565b65ffffffffffff1610806131795750600361316f606083016040840161476c565b65ffffffffffff16115b1561319757604051633951a25360e01b815260040160405180910390fd5b6131a8826131a3612780565b6133f3565b505061ffff82166000908152600260209081526040909120906131cd90830183614787565b815463ffffffff91909116600160e01b026001600160e01b039091161781556131fc60408301602084016147a2565b6001820180546001600160b01b03166001600160481b0392909216600160b01b02919091179055613233606083016040840161476c565b61ffff84166000818152600660209081526040909120805465ffffffffffff191665ffffffffffff9490941693909317909255907ffe3f382c07994321b091a508fb27d2cec41f6dfa9f52b97a01af5b992fdc16819061329590850185614787565b6132a560408601602087016147a2565b6132b5606087016040880161476c565b6040805163ffffffff90941684526001600160481b03909216602084015265ffffffffffff169082015260600160405180910390a2505050565b6000806132fc8484611447565b5060008681526003602052604090206001810180546001600160401b03808616600160201b026bffffffffffffffff0000000019918616600160601b0291909116640100000000600160a01b0319909216919091171790559193509150613362846136e4565b60018201805465ffffffffffff92909216600160a01b0265ffffffffffff60a01b199092169190911790819055604080518681526001600160401b03600160201b840481166020830152600160601b9093049092169082015285907ffc346088168e874385f54275cfc143d52a459a0fdc016c1bb6c237097ef27bf4906060015b60405180910390a2509250929050565b60008061340084846119dc565b5061ffff861660009081526002602052604090206001810180546001600160801b031916600160401b6001600160401b038581169190910267ffffffffffffffff191691909117908516179055919350915061345b846136e4565b60018201805465ffffffffffff92909216600160801b0265ffffffffffff60801b198316811791829055604080518881526001600160401b03928316948316949094176020850152600160401b909204169082015261ffff8616907fd246da22fc6064e2fae4f4affdb9425eac12bebcf4f08fb3892f08480513752e906060016133e3565b61ffff841660008181526002602052604081209115613677576009546001600160801b03166135146402540be400856143cc565b61351e91906143e3565b92506001600160701b0383111561354857604051631a93c68960e11b815260040160405180910390fd5b508184156135d257836135955781546001600160701b038083169116116135795781546001600160701b031661357b565b805b825461359091906001600160701b03166147bd565b6135ab565b81546135ab9082906001600160701b03166147dd565b82546dffffffffffffffffffffffffffff19166001600160701b0391909116178255613677565b8361362c5781546001600160701b03808316600160701b9092041611613609578154600160701b90046001600160701b031661360b565b805b82546136279190600160701b90046001600160701b03166147bd565b613649565b8154613649908290600160701b90046001600160701b03166147dd565b82546001600160701b0391909116600160701b026dffffffffffffffffffffffffffff60701b199091161782555b8154604080516001600160701b0380851682528084166020830152600160701b90930490921690820152841515908615159061ffff8916907f946036ec838a96db6089510038e2de4a934fb985f2ba9ef85dd4166f622db2339060600160405180910390a4505050505050565b600065ffffffffffff82111561370d57604051631a93c68960e11b815260040160405180910390fd5b5090565b6040805161010081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e081019190915290565b6040805160e081018252606080825260006020830181905292820183905281018290526080810182905260a0810182905260c081019190915290565b6000602082840312156137a357600080fd5b5035919050565b634e487b7160e01b600052604160045260246000fd5b60405161012081016001600160401b03811182821017156137e3576137e36137aa565b60405290565b60405161014081016001600160401b03811182821017156137e3576137e36137aa565b604051601f8201601f191681016001600160401b0381118282101715613834576138346137aa565b604052919050565b803561ffff8116811461384e57600080fd5b919050565b803565ffffffffffff8116811461384e57600080fd5b6001600160401b038116811461387e57600080fd5b50565b803561384e81613869565b60006080828403121561389e57600080fd5b604051608081018181106001600160401b03821117156138c0576138c06137aa565b60405290508082356138d181613869565b815260208301356138e181613869565b60208201526138f260408401613853565b604082015260608301356001600160501b038116811461391157600080fd5b6060919091015292915050565b801515811461387e57600080fd5b803561384e8161391e565b60008060008060008061012080888a03121561395257600080fd5b873596506020808901356001600160401b038082111561397157600080fd5b818b0191508b601f83011261398557600080fd5b813581811115613997576139976137aa565b6139a5848260051b0161380c565b818152848101925090850283018401908d8211156139c257600080fd5b928401925b81841015613a885785848f0312156139df5760008081fd5b6139e76137c0565b6139f08561383c565b81526139fd868601613853565b868201526040613a0e818701613881565b908201526060613a1f868201613881565b908201526080613a30868201613881565b9082015260a0613a41868201613881565b9082015260c0613a52868201613881565b9082015260e0613a63868201613881565b90820152610100613a75868201613881565b90820152835292850192918401916139c7565b809a50505050505050613a9e886040890161388c565b935060c08701359250613ab360e0880161392c565b915061010087013590509295509295509295565b600080600060608486031215613adc57600080fd5b613ae58461383c565b9250602084013591506040840135613afc8161391e565b809150509250925092565b60008083601f840112613b1957600080fd5b5081356001600160401b03811115613b3057600080fd5b6020830191508360208260051b8501011115610c6657600080fd5b60008060208385031215613b5e57600080fd5b82356001600160401b03811115613b7457600080fd5b613b8085828601613b07565b90969095509350505050565b6001600160701b038082511683528060208301511660208401525063ffffffff604082015116604083015260608101516001600160401b038082166060850152806080840151166080850152505065ffffffffffff60a08201511660a083015260c0810151613c0660c08401826001600160501b03169052565b5060e090810151910152565b604080825283519082018190526000906020906060840190828701845b82811015613c5657613c42848351613b8c565b610100939093019290840190600101613c2f565b5050508381038285015284518082528583019183019060005b81811015613c9357835165ffffffffffff1683529284019291840191600101613c6f565b5090979650505050505050565b6001600160a01b038116811461387e57600080fd5b600060c08284031215613cc757600080fd5b60405160c081018181106001600160401b0382111715613ce957613ce96137aa565b6040528235613cf781613ca0565b8082525060208301356020820152604083013560408201526060830135613d1d8161391e565b60608201526080838101359082015260a0928301359281019290925250919050565b600060208284031215613d5157600080fd5b8135610a3a81613ca0565b600060208284031215613d6e57600080fd5b610a3a8261383c565b60008060008060408587031215613d8d57600080fd5b84356001600160401b0380821115613da457600080fd5b613db088838901613b07565b90965094506020870135915080821115613dc957600080fd5b818701915087601f830112613ddd57600080fd5b813581811115613dec57600080fd5b8860208260071b8501011115613e0157600080fd5b95989497505060200194505050565b600060e08284031215613e2257600080fd5b50919050565b600080600060608486031215613e3d57600080fd5b83359250602084013591506040840135613afc8161391e565b60008060408385031215613e6957600080fd5b50508035926020909101359150565b600080600060608486031215613e8d57600080fd5b8335613e9881613ca0565b95602085013595506040909401359392505050565b6000808284036080811215613ec157600080fd5b613eca8461383c565b92506060601f1982011215613ede57600080fd5b506020830190509250929050565b60008082840360a0811215613f0057600080fd5b833592506080601f1982011215613ede57600080fd5b60008060008060408587031215613f2c57600080fd5b84356001600160401b0380821115613f4357600080fd5b613f4f88838901613b07565b90965094506020870135915080821115613f6857600080fd5b818701915087601f830112613f7c57600080fd5b813581811115613f8b57600080fd5b886020606083028501011115613e0157600080fd5b60008060408385031215613fb357600080fd5b613fbc8361383c565b946020939093013593505050565b805160e08084528151848201819052600092610100916020918201918388019190865b8281101561407d578451805161ffff1685528281015165ffffffffffff16838601526040808201516001600160401b039081169187019190915260608083015182169087015260808083015182169087015260a08083015182169087015260c080830151821690870152888201518116898701529087015116868501529381019361012090930192600101613fed565b508781015163ffffffff1690890152506040808701516001600160401b0390811691890191909152606080880151918216908901529350608086015193506140cf608088018565ffffffffffff169052565b60a086015193506140ea60a088018565ffffffffffff169052565b60c086015160c08801528094505050505092915050565b6001600160481b038082511683528060208301511660208401528060408301511660408401525064ffffffffff60608201511660608301525050565b60a08152600061415060a0830185613fca565b9050610a3a6020830184614101565b803563ffffffff8116811461384e57600080fd5b80356001600160481b038116811461384e57600080fd5b80356001600160801b038116811461384e57600080fd5b600061014082840312156141b457600080fd5b6141bc6137e9565b6141c583613881565b81526141d360208401613881565b602082015260408301356040820152606083013560608201526141f86080840161415f565b608082015260a083013560a082015260c083013560c082015261421d60e08401614173565b60e0820152610100614230818501613853565b9082015261012061424284820161418a565b908201529392505050565b60008060008060008060c0878903121561426657600080fd5b863561427181613ca0565b955060208701359450604087013593506060870135925060808701356142968161391e565b915060a08701356142a68161391e565b809150509295509295509295565b6000806000606084860312156142c957600080fd5b8335925060208401356142db8161391e565b929592945050506040919091013590565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b8381101561434357605f19888703018552614331868351613fca565b95509382019390820190600101614315565b50508584038187015286518085528782019482019350915060005b8281101561438457614371848651614101565b938101936080939093019260010161435e565b5091979650505050505050565b61012081016143a08285613b8c565b65ffffffffffff83166101008301529392505050565b634e487b7160e01b600052601160045260246000fd5b808202811582820484141761088e5761088e6143b6565b60008261440057634e487b7160e01b600052601260045260246000fd5b500490565b634e487b7160e01b600052603260045260246000fd5b8181038181111561088e5761088e6143b6565b8082018082111561088e5761088e6143b6565b6001600160401b03828116828216039080821115614461576144616143b6565b5092915050565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b6000602082840312156144c857600080fd5b8151610a3a81613ca0565b6000602082840312156144e557600080fd5b5051919050565b6001600160a01b0383168152604081016006831061451a57634e487b7160e01b600052602160045260246000fd5b8260208301529392505050565b60006020828403121561453957600080fd5b8151610a3a8161391e565b60006020828403121561455657600080fd5b8135610a3a8161391e565b81516001600160401b031681526101408101602083015161458d60208401826001600160401b03169052565b50604083015160408301526060830151606083015260808301516145b9608084018263ffffffff169052565b5060a083015160a083015260c083015160c083015260e08301516145e860e08401826001600160481b03169052565b506101008381015165ffffffffffff1690830152610120928301516001600160801b0316929091019190915290565b60008060006060848603121561462c57600080fd5b835161463781613869565b602085015190935061464881613869565b6040850151909250613afc81613869565b60006020828403121561466b57600080fd5b815160ff81168114610a3a57600080fd5b600181815b808511156146b757816000190482111561469d5761469d6143b6565b808516156146aa57918102915b93841c9390800290614681565b509250929050565b6000826146ce5750600161088e565b816146db5750600061088e565b81600181146146f157600281146146fb57614717565b600191505061088e565b60ff84111561470c5761470c6143b6565b50506001821b61088e565b5060208310610133831016604e8410600b841016171561473a575081810a61088e565b614744838361467c565b8060001904821115614758576147586143b6565b029392505050565b6000610a3a83836146bf565b60006020828403121561477e57600080fd5b610a3a82613853565b60006020828403121561479957600080fd5b610a3a8261415f565b6000602082840312156147b457600080fd5b610a3a82614173565b6001600160701b03828116828216039080821115614461576144616143b6565b6001600160701b03818116838216019080821115614461576144616143b656fea26469706673582212205ae53779445344e273896c45609252ef8d5a712c628499d8c318390ae2b7aa8564736f6c63430008110033";
1741
- const isSuperArgs = (xs) => {
1742
- return (typeof xs[0] === "string" ||
1743
- Array.isArray(xs[0]) ||
1744
- "_isInterface" in xs[0]);
1745
- };
1746
- class GNSBorrowingFees__factory extends ethers_1.ContractFactory {
1747
- constructor(...args) {
1748
- if (isSuperArgs(args)) {
1749
- super(...args);
1750
- }
1751
- else {
1752
- const [linkLibraryAddresses, signer] = args;
1753
- super(_abi, GNSBorrowingFees__factory.linkBytecode(linkLibraryAddresses), signer);
1754
- }
1755
- }
1756
- static linkBytecode(linkLibraryAddresses) {
1757
- let linkedBytecode = _bytecode;
1758
- linkedBytecode = linkedBytecode.replace(new RegExp("__\\$80699a18f5fb835ede6cb415cbdea2f026\\$__", "g"), linkLibraryAddresses["contracts/libraries/BorrowingFeesUtils.sol:BorrowingFeesUtils"]
1759
- .replace(/^0x/, "")
1760
- .toLowerCase());
1761
- return linkedBytecode;
1762
- }
1763
- deploy(overrides) {
1764
- return super.deploy(overrides || {});
1765
- }
1766
- getDeployTransaction(overrides) {
1767
- return super.getDeployTransaction(overrides || {});
1768
- }
1769
- attach(address) {
1770
- return super.attach(address);
1771
- }
1772
- connect(signer) {
1773
- return super.connect(signer);
1774
- }
1775
- static createInterface() {
1776
- return new ethers_1.utils.Interface(_abi);
1777
- }
1778
- static connect(address, signerOrProvider) {
1779
- return new ethers_1.Contract(address, _abi, signerOrProvider);
1780
- }
1781
- }
1782
- exports.GNSBorrowingFees__factory = GNSBorrowingFees__factory;
1783
- GNSBorrowingFees__factory.bytecode = _bytecode;
1784
- GNSBorrowingFees__factory.abi = _abi;