@gainsnetwork/sdk 1.5.0-rc2 → 1.5.0-rc4

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