-
Notifications
You must be signed in to change notification settings - Fork 126
/
curvefi.go
1749 lines (1431 loc) · 83 KB
/
curvefi.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
// Code generated - DO NOT EDIT.
// This file is a generated binding and any manual changes will be lost.
package curvefi
import (
"errors"
"math/big"
"strings"
ethereum "github.com/ethereum/go-ethereum"
"github.com/ethereum/go-ethereum/accounts/abi"
"github.com/ethereum/go-ethereum/accounts/abi/bind"
"github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/core/types"
"github.com/ethereum/go-ethereum/event"
)
// Reference imports to suppress errors if they are not otherwise used.
var (
_ = errors.New
_ = big.NewInt
_ = strings.NewReader
_ = ethereum.NotFound
_ = bind.Bind
_ = common.Big1
_ = types.BloomLookup
_ = event.NewSubscription
)
// CurvefiMetaData contains all meta data concerning the Curvefi contract.
var CurvefiMetaData = &bind.MetaData{
ABI: "[{\"name\":\"PoolAdded\",\"inputs\":[{\"name\":\"pool\",\"type\":\"address\",\"indexed\":true},{\"name\":\"rate_method_id\",\"type\":\"bytes\",\"indexed\":false}],\"anonymous\":false,\"type\":\"event\"},{\"name\":\"PoolRemoved\",\"inputs\":[{\"name\":\"pool\",\"type\":\"address\",\"indexed\":true}],\"anonymous\":false,\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"constructor\",\"inputs\":[{\"name\":\"_address_provider\",\"type\":\"address\"},{\"name\":\"_gauge_controller\",\"type\":\"address\"}],\"outputs\":[]},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"find_pool_for_coins\",\"inputs\":[{\"name\":\"_from\",\"type\":\"address\"},{\"name\":\"_to\",\"type\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"address\"}]},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"find_pool_for_coins\",\"inputs\":[{\"name\":\"_from\",\"type\":\"address\"},{\"name\":\"_to\",\"type\":\"address\"},{\"name\":\"i\",\"type\":\"uint256\"}],\"outputs\":[{\"name\":\"\",\"type\":\"address\"}]},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"get_n_coins\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256[2]\"}],\"gas\":1521},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"get_coins\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"address[8]\"}],\"gas\":12102},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"get_underlying_coins\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"address[8]\"}],\"gas\":12194},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"get_decimals\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256[8]\"}],\"gas\":7874},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"get_underlying_decimals\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256[8]\"}],\"gas\":7966},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"get_rates\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256[8]\"}],\"gas\":36992},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"get_gauges\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"address[10]\"},{\"name\":\"\",\"type\":\"int128[10]\"}],\"gas\":20157},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"get_balances\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256[8]\"}],\"gas\":16583},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"get_underlying_balances\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256[8]\"}],\"gas\":162842},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"get_virtual_price_from_lp_token\",\"inputs\":[{\"name\":\"_token\",\"type\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"gas\":1927},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"get_A\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"gas\":1045},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"get_parameters\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"}],\"outputs\":[{\"name\":\"A\",\"type\":\"uint256\"},{\"name\":\"future_A\",\"type\":\"uint256\"},{\"name\":\"fee\",\"type\":\"uint256\"},{\"name\":\"admin_fee\",\"type\":\"uint256\"},{\"name\":\"future_fee\",\"type\":\"uint256\"},{\"name\":\"future_admin_fee\",\"type\":\"uint256\"},{\"name\":\"future_owner\",\"type\":\"address\"},{\"name\":\"initial_A\",\"type\":\"uint256\"},{\"name\":\"initial_A_time\",\"type\":\"uint256\"},{\"name\":\"future_A_time\",\"type\":\"uint256\"}],\"gas\":6305},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"get_fees\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256[2]\"}],\"gas\":1450},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"get_admin_balances\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256[8]\"}],\"gas\":36454},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"get_coin_indices\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"},{\"name\":\"_from\",\"type\":\"address\"},{\"name\":\"_to\",\"type\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"int128\"},{\"name\":\"\",\"type\":\"int128\"},{\"name\":\"\",\"type\":\"bool\"}],\"gas\":27131},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"estimate_gas_used\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"},{\"name\":\"_from\",\"type\":\"address\"},{\"name\":\"_to\",\"type\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"gas\":32004},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"is_meta\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"gas\":1900},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"get_pool_name\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"gas\":8323},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"get_coin_swap_count\",\"inputs\":[{\"name\":\"_coin\",\"type\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"gas\":1951},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"get_coin_swap_complement\",\"inputs\":[{\"name\":\"_coin\",\"type\":\"address\"},{\"name\":\"_index\",\"type\":\"uint256\"}],\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"gas\":2090},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"get_pool_asset_type\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"gas\":2011},{\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"add_pool\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"},{\"name\":\"_n_coins\",\"type\":\"uint256\"},{\"name\":\"_lp_token\",\"type\":\"address\"},{\"name\":\"_rate_info\",\"type\":\"bytes32\"},{\"name\":\"_decimals\",\"type\":\"uint256\"},{\"name\":\"_underlying_decimals\",\"type\":\"uint256\"},{\"name\":\"_has_initial_A\",\"type\":\"bool\"},{\"name\":\"_is_v1\",\"type\":\"bool\"},{\"name\":\"_name\",\"type\":\"string\"}],\"outputs\":[],\"gas\":61485845},{\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"add_pool_without_underlying\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"},{\"name\":\"_n_coins\",\"type\":\"uint256\"},{\"name\":\"_lp_token\",\"type\":\"address\"},{\"name\":\"_rate_info\",\"type\":\"bytes32\"},{\"name\":\"_decimals\",\"type\":\"uint256\"},{\"name\":\"_use_rates\",\"type\":\"uint256\"},{\"name\":\"_has_initial_A\",\"type\":\"bool\"},{\"name\":\"_is_v1\",\"type\":\"bool\"},{\"name\":\"_name\",\"type\":\"string\"}],\"outputs\":[],\"gas\":31306062},{\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"add_metapool\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"},{\"name\":\"_n_coins\",\"type\":\"uint256\"},{\"name\":\"_lp_token\",\"type\":\"address\"},{\"name\":\"_decimals\",\"type\":\"uint256\"},{\"name\":\"_name\",\"type\":\"string\"}],\"outputs\":[]},{\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"add_metapool\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"},{\"name\":\"_n_coins\",\"type\":\"uint256\"},{\"name\":\"_lp_token\",\"type\":\"address\"},{\"name\":\"_decimals\",\"type\":\"uint256\"},{\"name\":\"_name\",\"type\":\"string\"},{\"name\":\"_base_pool\",\"type\":\"address\"}],\"outputs\":[]},{\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"remove_pool\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"}],\"outputs\":[],\"gas\":779731418758},{\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"set_pool_gas_estimates\",\"inputs\":[{\"name\":\"_addr\",\"type\":\"address[5]\"},{\"name\":\"_amount\",\"type\":\"uint256[2][5]\"}],\"outputs\":[],\"gas\":390460},{\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"set_coin_gas_estimates\",\"inputs\":[{\"name\":\"_addr\",\"type\":\"address[10]\"},{\"name\":\"_amount\",\"type\":\"uint256[10]\"}],\"outputs\":[],\"gas\":392047},{\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"set_gas_estimate_contract\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"},{\"name\":\"_estimator\",\"type\":\"address\"}],\"outputs\":[],\"gas\":72629},{\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"set_liquidity_gauges\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"},{\"name\":\"_liquidity_gauges\",\"type\":\"address[10]\"}],\"outputs\":[],\"gas\":400675},{\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"set_pool_asset_type\",\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"},{\"name\":\"_asset_type\",\"type\":\"uint256\"}],\"outputs\":[],\"gas\":72667},{\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"batch_set_pool_asset_type\",\"inputs\":[{\"name\":\"_pools\",\"type\":\"address[32]\"},{\"name\":\"_asset_types\",\"type\":\"uint256[32]\"}],\"outputs\":[],\"gas\":1173447},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"address_provider\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"gas\":2048},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"gauge_controller\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"gas\":2078},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"pool_list\",\"inputs\":[{\"name\":\"arg0\",\"type\":\"uint256\"}],\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"gas\":2217},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"pool_count\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"gas\":2138},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"coin_count\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"gas\":2168},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"get_coin\",\"inputs\":[{\"name\":\"arg0\",\"type\":\"uint256\"}],\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"gas\":2307},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"get_pool_from_lp_token\",\"inputs\":[{\"name\":\"arg0\",\"type\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"gas\":2443},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"get_lp_token\",\"inputs\":[{\"name\":\"arg0\",\"type\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"gas\":2473},{\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"last_updated\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"gas\":2288}]",
}
// CurvefiABI is the input ABI used to generate the binding from.
// Deprecated: Use CurvefiMetaData.ABI instead.
var CurvefiABI = CurvefiMetaData.ABI
// Curvefi is an auto generated Go binding around an Ethereum contract.
type Curvefi struct {
CurvefiCaller // Read-only binding to the contract
CurvefiTransactor // Write-only binding to the contract
CurvefiFilterer // Log filterer for contract events
}
// CurvefiCaller is an auto generated read-only Go binding around an Ethereum contract.
type CurvefiCaller struct {
contract *bind.BoundContract // Generic contract wrapper for the low level calls
}
// CurvefiTransactor is an auto generated write-only Go binding around an Ethereum contract.
type CurvefiTransactor struct {
contract *bind.BoundContract // Generic contract wrapper for the low level calls
}
// CurvefiFilterer is an auto generated log filtering Go binding around an Ethereum contract events.
type CurvefiFilterer struct {
contract *bind.BoundContract // Generic contract wrapper for the low level calls
}
// CurvefiSession is an auto generated Go binding around an Ethereum contract,
// with pre-set call and transact options.
type CurvefiSession struct {
Contract *Curvefi // Generic contract binding to set the session for
CallOpts bind.CallOpts // Call options to use throughout this session
TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session
}
// CurvefiCallerSession is an auto generated read-only Go binding around an Ethereum contract,
// with pre-set call options.
type CurvefiCallerSession struct {
Contract *CurvefiCaller // Generic contract caller binding to set the session for
CallOpts bind.CallOpts // Call options to use throughout this session
}
// CurvefiTransactorSession is an auto generated write-only Go binding around an Ethereum contract,
// with pre-set transact options.
type CurvefiTransactorSession struct {
Contract *CurvefiTransactor // Generic contract transactor binding to set the session for
TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session
}
// CurvefiRaw is an auto generated low-level Go binding around an Ethereum contract.
type CurvefiRaw struct {
Contract *Curvefi // Generic contract binding to access the raw methods on
}
// CurvefiCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract.
type CurvefiCallerRaw struct {
Contract *CurvefiCaller // Generic read-only contract binding to access the raw methods on
}
// CurvefiTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract.
type CurvefiTransactorRaw struct {
Contract *CurvefiTransactor // Generic write-only contract binding to access the raw methods on
}
// NewCurvefi creates a new instance of Curvefi, bound to a specific deployed contract.
func NewCurvefi(address common.Address, backend bind.ContractBackend) (*Curvefi, error) {
contract, err := bindCurvefi(address, backend, backend, backend)
if err != nil {
return nil, err
}
return &Curvefi{CurvefiCaller: CurvefiCaller{contract: contract}, CurvefiTransactor: CurvefiTransactor{contract: contract}, CurvefiFilterer: CurvefiFilterer{contract: contract}}, nil
}
// NewCurvefiCaller creates a new read-only instance of Curvefi, bound to a specific deployed contract.
func NewCurvefiCaller(address common.Address, caller bind.ContractCaller) (*CurvefiCaller, error) {
contract, err := bindCurvefi(address, caller, nil, nil)
if err != nil {
return nil, err
}
return &CurvefiCaller{contract: contract}, nil
}
// NewCurvefiTransactor creates a new write-only instance of Curvefi, bound to a specific deployed contract.
func NewCurvefiTransactor(address common.Address, transactor bind.ContractTransactor) (*CurvefiTransactor, error) {
contract, err := bindCurvefi(address, nil, transactor, nil)
if err != nil {
return nil, err
}
return &CurvefiTransactor{contract: contract}, nil
}
// NewCurvefiFilterer creates a new log filterer instance of Curvefi, bound to a specific deployed contract.
func NewCurvefiFilterer(address common.Address, filterer bind.ContractFilterer) (*CurvefiFilterer, error) {
contract, err := bindCurvefi(address, nil, nil, filterer)
if err != nil {
return nil, err
}
return &CurvefiFilterer{contract: contract}, nil
}
// bindCurvefi binds a generic wrapper to an already deployed contract.
func bindCurvefi(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) {
parsed, err := abi.JSON(strings.NewReader(CurvefiABI))
if err != nil {
return nil, err
}
return bind.NewBoundContract(address, parsed, caller, transactor, filterer), nil
}
// Call invokes the (constant) contract method with params as input values and
// sets the output to result. The result type might be a single field for simple
// returns, a slice of interfaces for anonymous returns and a struct for named
// returns.
func (_Curvefi *CurvefiRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error {
return _Curvefi.Contract.CurvefiCaller.contract.Call(opts, result, method, params...)
}
// Transfer initiates a plain transaction to move funds to the contract, calling
// its default method if one is available.
func (_Curvefi *CurvefiRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) {
return _Curvefi.Contract.CurvefiTransactor.contract.Transfer(opts)
}
// Transact invokes the (paid) contract method with params as input values.
func (_Curvefi *CurvefiRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) {
return _Curvefi.Contract.CurvefiTransactor.contract.Transact(opts, method, params...)
}
// Call invokes the (constant) contract method with params as input values and
// sets the output to result. The result type might be a single field for simple
// returns, a slice of interfaces for anonymous returns and a struct for named
// returns.
func (_Curvefi *CurvefiCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error {
return _Curvefi.Contract.contract.Call(opts, result, method, params...)
}
// Transfer initiates a plain transaction to move funds to the contract, calling
// its default method if one is available.
func (_Curvefi *CurvefiTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) {
return _Curvefi.Contract.contract.Transfer(opts)
}
// Transact invokes the (paid) contract method with params as input values.
func (_Curvefi *CurvefiTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) {
return _Curvefi.Contract.contract.Transact(opts, method, params...)
}
// AddressProvider is a free data retrieval call binding the contract method 0xce50c2e7.
//
// Solidity: function address_provider() view returns(address)
func (_Curvefi *CurvefiCaller) AddressProvider(opts *bind.CallOpts) (common.Address, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "address_provider")
if err != nil {
return *new(common.Address), err
}
out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
return out0, err
}
// AddressProvider is a free data retrieval call binding the contract method 0xce50c2e7.
//
// Solidity: function address_provider() view returns(address)
func (_Curvefi *CurvefiSession) AddressProvider() (common.Address, error) {
return _Curvefi.Contract.AddressProvider(&_Curvefi.CallOpts)
}
// AddressProvider is a free data retrieval call binding the contract method 0xce50c2e7.
//
// Solidity: function address_provider() view returns(address)
func (_Curvefi *CurvefiCallerSession) AddressProvider() (common.Address, error) {
return _Curvefi.Contract.AddressProvider(&_Curvefi.CallOpts)
}
// CoinCount is a free data retrieval call binding the contract method 0x5075770f.
//
// Solidity: function coin_count() view returns(uint256)
func (_Curvefi *CurvefiCaller) CoinCount(opts *bind.CallOpts) (*big.Int, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "coin_count")
if err != nil {
return *new(*big.Int), err
}
out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int)
return out0, err
}
// CoinCount is a free data retrieval call binding the contract method 0x5075770f.
//
// Solidity: function coin_count() view returns(uint256)
func (_Curvefi *CurvefiSession) CoinCount() (*big.Int, error) {
return _Curvefi.Contract.CoinCount(&_Curvefi.CallOpts)
}
// CoinCount is a free data retrieval call binding the contract method 0x5075770f.
//
// Solidity: function coin_count() view returns(uint256)
func (_Curvefi *CurvefiCallerSession) CoinCount() (*big.Int, error) {
return _Curvefi.Contract.CoinCount(&_Curvefi.CallOpts)
}
// EstimateGasUsed is a free data retrieval call binding the contract method 0xb0bb365b.
//
// Solidity: function estimate_gas_used(address _pool, address _from, address _to) view returns(uint256)
func (_Curvefi *CurvefiCaller) EstimateGasUsed(opts *bind.CallOpts, _pool common.Address, _from common.Address, _to common.Address) (*big.Int, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "estimate_gas_used", _pool, _from, _to)
if err != nil {
return *new(*big.Int), err
}
out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int)
return out0, err
}
// EstimateGasUsed is a free data retrieval call binding the contract method 0xb0bb365b.
//
// Solidity: function estimate_gas_used(address _pool, address _from, address _to) view returns(uint256)
func (_Curvefi *CurvefiSession) EstimateGasUsed(_pool common.Address, _from common.Address, _to common.Address) (*big.Int, error) {
return _Curvefi.Contract.EstimateGasUsed(&_Curvefi.CallOpts, _pool, _from, _to)
}
// EstimateGasUsed is a free data retrieval call binding the contract method 0xb0bb365b.
//
// Solidity: function estimate_gas_used(address _pool, address _from, address _to) view returns(uint256)
func (_Curvefi *CurvefiCallerSession) EstimateGasUsed(_pool common.Address, _from common.Address, _to common.Address) (*big.Int, error) {
return _Curvefi.Contract.EstimateGasUsed(&_Curvefi.CallOpts, _pool, _from, _to)
}
// FindPoolForCoins is a free data retrieval call binding the contract method 0xa87df06c.
//
// Solidity: function find_pool_for_coins(address _from, address _to) view returns(address)
func (_Curvefi *CurvefiCaller) FindPoolForCoins(opts *bind.CallOpts, _from common.Address, _to common.Address) (common.Address, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "find_pool_for_coins", _from, _to)
if err != nil {
return *new(common.Address), err
}
out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
return out0, err
}
// FindPoolForCoins is a free data retrieval call binding the contract method 0xa87df06c.
//
// Solidity: function find_pool_for_coins(address _from, address _to) view returns(address)
func (_Curvefi *CurvefiSession) FindPoolForCoins(_from common.Address, _to common.Address) (common.Address, error) {
return _Curvefi.Contract.FindPoolForCoins(&_Curvefi.CallOpts, _from, _to)
}
// FindPoolForCoins is a free data retrieval call binding the contract method 0xa87df06c.
//
// Solidity: function find_pool_for_coins(address _from, address _to) view returns(address)
func (_Curvefi *CurvefiCallerSession) FindPoolForCoins(_from common.Address, _to common.Address) (common.Address, error) {
return _Curvefi.Contract.FindPoolForCoins(&_Curvefi.CallOpts, _from, _to)
}
// FindPoolForCoins0 is a free data retrieval call binding the contract method 0x6982eb0b.
//
// Solidity: function find_pool_for_coins(address _from, address _to, uint256 i) view returns(address)
func (_Curvefi *CurvefiCaller) FindPoolForCoins0(opts *bind.CallOpts, _from common.Address, _to common.Address, i *big.Int) (common.Address, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "find_pool_for_coins0", _from, _to, i)
if err != nil {
return *new(common.Address), err
}
out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
return out0, err
}
// FindPoolForCoins0 is a free data retrieval call binding the contract method 0x6982eb0b.
//
// Solidity: function find_pool_for_coins(address _from, address _to, uint256 i) view returns(address)
func (_Curvefi *CurvefiSession) FindPoolForCoins0(_from common.Address, _to common.Address, i *big.Int) (common.Address, error) {
return _Curvefi.Contract.FindPoolForCoins0(&_Curvefi.CallOpts, _from, _to, i)
}
// FindPoolForCoins0 is a free data retrieval call binding the contract method 0x6982eb0b.
//
// Solidity: function find_pool_for_coins(address _from, address _to, uint256 i) view returns(address)
func (_Curvefi *CurvefiCallerSession) FindPoolForCoins0(_from common.Address, _to common.Address, i *big.Int) (common.Address, error) {
return _Curvefi.Contract.FindPoolForCoins0(&_Curvefi.CallOpts, _from, _to, i)
}
// GaugeController is a free data retrieval call binding the contract method 0xd8b9a018.
//
// Solidity: function gauge_controller() view returns(address)
func (_Curvefi *CurvefiCaller) GaugeController(opts *bind.CallOpts) (common.Address, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "gauge_controller")
if err != nil {
return *new(common.Address), err
}
out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
return out0, err
}
// GaugeController is a free data retrieval call binding the contract method 0xd8b9a018.
//
// Solidity: function gauge_controller() view returns(address)
func (_Curvefi *CurvefiSession) GaugeController() (common.Address, error) {
return _Curvefi.Contract.GaugeController(&_Curvefi.CallOpts)
}
// GaugeController is a free data retrieval call binding the contract method 0xd8b9a018.
//
// Solidity: function gauge_controller() view returns(address)
func (_Curvefi *CurvefiCallerSession) GaugeController() (common.Address, error) {
return _Curvefi.Contract.GaugeController(&_Curvefi.CallOpts)
}
// GetA is a free data retrieval call binding the contract method 0x55b30b19.
//
// Solidity: function get_A(address _pool) view returns(uint256)
func (_Curvefi *CurvefiCaller) GetA(opts *bind.CallOpts, _pool common.Address) (*big.Int, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "get_A", _pool)
if err != nil {
return *new(*big.Int), err
}
out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int)
return out0, err
}
// GetA is a free data retrieval call binding the contract method 0x55b30b19.
//
// Solidity: function get_A(address _pool) view returns(uint256)
func (_Curvefi *CurvefiSession) GetA(_pool common.Address) (*big.Int, error) {
return _Curvefi.Contract.GetA(&_Curvefi.CallOpts, _pool)
}
// GetA is a free data retrieval call binding the contract method 0x55b30b19.
//
// Solidity: function get_A(address _pool) view returns(uint256)
func (_Curvefi *CurvefiCallerSession) GetA(_pool common.Address) (*big.Int, error) {
return _Curvefi.Contract.GetA(&_Curvefi.CallOpts, _pool)
}
// GetAdminBalances is a free data retrieval call binding the contract method 0xc11e45b8.
//
// Solidity: function get_admin_balances(address _pool) view returns(uint256[8])
func (_Curvefi *CurvefiCaller) GetAdminBalances(opts *bind.CallOpts, _pool common.Address) ([8]*big.Int, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "get_admin_balances", _pool)
if err != nil {
return *new([8]*big.Int), err
}
out0 := *abi.ConvertType(out[0], new([8]*big.Int)).(*[8]*big.Int)
return out0, err
}
// GetAdminBalances is a free data retrieval call binding the contract method 0xc11e45b8.
//
// Solidity: function get_admin_balances(address _pool) view returns(uint256[8])
func (_Curvefi *CurvefiSession) GetAdminBalances(_pool common.Address) ([8]*big.Int, error) {
return _Curvefi.Contract.GetAdminBalances(&_Curvefi.CallOpts, _pool)
}
// GetAdminBalances is a free data retrieval call binding the contract method 0xc11e45b8.
//
// Solidity: function get_admin_balances(address _pool) view returns(uint256[8])
func (_Curvefi *CurvefiCallerSession) GetAdminBalances(_pool common.Address) ([8]*big.Int, error) {
return _Curvefi.Contract.GetAdminBalances(&_Curvefi.CallOpts, _pool)
}
// GetBalances is a free data retrieval call binding the contract method 0x92e3cc2d.
//
// Solidity: function get_balances(address _pool) view returns(uint256[8])
func (_Curvefi *CurvefiCaller) GetBalances(opts *bind.CallOpts, _pool common.Address) ([8]*big.Int, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "get_balances", _pool)
if err != nil {
return *new([8]*big.Int), err
}
out0 := *abi.ConvertType(out[0], new([8]*big.Int)).(*[8]*big.Int)
return out0, err
}
// GetBalances is a free data retrieval call binding the contract method 0x92e3cc2d.
//
// Solidity: function get_balances(address _pool) view returns(uint256[8])
func (_Curvefi *CurvefiSession) GetBalances(_pool common.Address) ([8]*big.Int, error) {
return _Curvefi.Contract.GetBalances(&_Curvefi.CallOpts, _pool)
}
// GetBalances is a free data retrieval call binding the contract method 0x92e3cc2d.
//
// Solidity: function get_balances(address _pool) view returns(uint256[8])
func (_Curvefi *CurvefiCallerSession) GetBalances(_pool common.Address) ([8]*big.Int, error) {
return _Curvefi.Contract.GetBalances(&_Curvefi.CallOpts, _pool)
}
// GetCoin is a free data retrieval call binding the contract method 0x45f0db24.
//
// Solidity: function get_coin(uint256 arg0) view returns(address)
func (_Curvefi *CurvefiCaller) GetCoin(opts *bind.CallOpts, arg0 *big.Int) (common.Address, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "get_coin", arg0)
if err != nil {
return *new(common.Address), err
}
out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
return out0, err
}
// GetCoin is a free data retrieval call binding the contract method 0x45f0db24.
//
// Solidity: function get_coin(uint256 arg0) view returns(address)
func (_Curvefi *CurvefiSession) GetCoin(arg0 *big.Int) (common.Address, error) {
return _Curvefi.Contract.GetCoin(&_Curvefi.CallOpts, arg0)
}
// GetCoin is a free data retrieval call binding the contract method 0x45f0db24.
//
// Solidity: function get_coin(uint256 arg0) view returns(address)
func (_Curvefi *CurvefiCallerSession) GetCoin(arg0 *big.Int) (common.Address, error) {
return _Curvefi.Contract.GetCoin(&_Curvefi.CallOpts, arg0)
}
// GetCoinIndices is a free data retrieval call binding the contract method 0xeb85226d.
//
// Solidity: function get_coin_indices(address _pool, address _from, address _to) view returns(int128, int128, bool)
func (_Curvefi *CurvefiCaller) GetCoinIndices(opts *bind.CallOpts, _pool common.Address, _from common.Address, _to common.Address) (*big.Int, *big.Int, bool, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "get_coin_indices", _pool, _from, _to)
if err != nil {
return *new(*big.Int), *new(*big.Int), *new(bool), err
}
out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int)
out1 := *abi.ConvertType(out[1], new(*big.Int)).(**big.Int)
out2 := *abi.ConvertType(out[2], new(bool)).(*bool)
return out0, out1, out2, err
}
// GetCoinIndices is a free data retrieval call binding the contract method 0xeb85226d.
//
// Solidity: function get_coin_indices(address _pool, address _from, address _to) view returns(int128, int128, bool)
func (_Curvefi *CurvefiSession) GetCoinIndices(_pool common.Address, _from common.Address, _to common.Address) (*big.Int, *big.Int, bool, error) {
return _Curvefi.Contract.GetCoinIndices(&_Curvefi.CallOpts, _pool, _from, _to)
}
// GetCoinIndices is a free data retrieval call binding the contract method 0xeb85226d.
//
// Solidity: function get_coin_indices(address _pool, address _from, address _to) view returns(int128, int128, bool)
func (_Curvefi *CurvefiCallerSession) GetCoinIndices(_pool common.Address, _from common.Address, _to common.Address) (*big.Int, *big.Int, bool, error) {
return _Curvefi.Contract.GetCoinIndices(&_Curvefi.CallOpts, _pool, _from, _to)
}
// GetCoinSwapComplement is a free data retrieval call binding the contract method 0x5d211982.
//
// Solidity: function get_coin_swap_complement(address _coin, uint256 _index) view returns(address)
func (_Curvefi *CurvefiCaller) GetCoinSwapComplement(opts *bind.CallOpts, _coin common.Address, _index *big.Int) (common.Address, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "get_coin_swap_complement", _coin, _index)
if err != nil {
return *new(common.Address), err
}
out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
return out0, err
}
// GetCoinSwapComplement is a free data retrieval call binding the contract method 0x5d211982.
//
// Solidity: function get_coin_swap_complement(address _coin, uint256 _index) view returns(address)
func (_Curvefi *CurvefiSession) GetCoinSwapComplement(_coin common.Address, _index *big.Int) (common.Address, error) {
return _Curvefi.Contract.GetCoinSwapComplement(&_Curvefi.CallOpts, _coin, _index)
}
// GetCoinSwapComplement is a free data retrieval call binding the contract method 0x5d211982.
//
// Solidity: function get_coin_swap_complement(address _coin, uint256 _index) view returns(address)
func (_Curvefi *CurvefiCallerSession) GetCoinSwapComplement(_coin common.Address, _index *big.Int) (common.Address, error) {
return _Curvefi.Contract.GetCoinSwapComplement(&_Curvefi.CallOpts, _coin, _index)
}
// GetCoinSwapCount is a free data retrieval call binding the contract method 0x98aede16.
//
// Solidity: function get_coin_swap_count(address _coin) view returns(uint256)
func (_Curvefi *CurvefiCaller) GetCoinSwapCount(opts *bind.CallOpts, _coin common.Address) (*big.Int, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "get_coin_swap_count", _coin)
if err != nil {
return *new(*big.Int), err
}
out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int)
return out0, err
}
// GetCoinSwapCount is a free data retrieval call binding the contract method 0x98aede16.
//
// Solidity: function get_coin_swap_count(address _coin) view returns(uint256)
func (_Curvefi *CurvefiSession) GetCoinSwapCount(_coin common.Address) (*big.Int, error) {
return _Curvefi.Contract.GetCoinSwapCount(&_Curvefi.CallOpts, _coin)
}
// GetCoinSwapCount is a free data retrieval call binding the contract method 0x98aede16.
//
// Solidity: function get_coin_swap_count(address _coin) view returns(uint256)
func (_Curvefi *CurvefiCallerSession) GetCoinSwapCount(_coin common.Address) (*big.Int, error) {
return _Curvefi.Contract.GetCoinSwapCount(&_Curvefi.CallOpts, _coin)
}
// GetCoins is a free data retrieval call binding the contract method 0x9ac90d3d.
//
// Solidity: function get_coins(address _pool) view returns(address[8])
func (_Curvefi *CurvefiCaller) GetCoins(opts *bind.CallOpts, _pool common.Address) ([8]common.Address, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "get_coins", _pool)
if err != nil {
return *new([8]common.Address), err
}
out0 := *abi.ConvertType(out[0], new([8]common.Address)).(*[8]common.Address)
return out0, err
}
// GetCoins is a free data retrieval call binding the contract method 0x9ac90d3d.
//
// Solidity: function get_coins(address _pool) view returns(address[8])
func (_Curvefi *CurvefiSession) GetCoins(_pool common.Address) ([8]common.Address, error) {
return _Curvefi.Contract.GetCoins(&_Curvefi.CallOpts, _pool)
}
// GetCoins is a free data retrieval call binding the contract method 0x9ac90d3d.
//
// Solidity: function get_coins(address _pool) view returns(address[8])
func (_Curvefi *CurvefiCallerSession) GetCoins(_pool common.Address) ([8]common.Address, error) {
return _Curvefi.Contract.GetCoins(&_Curvefi.CallOpts, _pool)
}
// GetDecimals is a free data retrieval call binding the contract method 0x52b51555.
//
// Solidity: function get_decimals(address _pool) view returns(uint256[8])
func (_Curvefi *CurvefiCaller) GetDecimals(opts *bind.CallOpts, _pool common.Address) ([8]*big.Int, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "get_decimals", _pool)
if err != nil {
return *new([8]*big.Int), err
}
out0 := *abi.ConvertType(out[0], new([8]*big.Int)).(*[8]*big.Int)
return out0, err
}
// GetDecimals is a free data retrieval call binding the contract method 0x52b51555.
//
// Solidity: function get_decimals(address _pool) view returns(uint256[8])
func (_Curvefi *CurvefiSession) GetDecimals(_pool common.Address) ([8]*big.Int, error) {
return _Curvefi.Contract.GetDecimals(&_Curvefi.CallOpts, _pool)
}
// GetDecimals is a free data retrieval call binding the contract method 0x52b51555.
//
// Solidity: function get_decimals(address _pool) view returns(uint256[8])
func (_Curvefi *CurvefiCallerSession) GetDecimals(_pool common.Address) ([8]*big.Int, error) {
return _Curvefi.Contract.GetDecimals(&_Curvefi.CallOpts, _pool)
}
// GetFees is a free data retrieval call binding the contract method 0x7cdb72b0.
//
// Solidity: function get_fees(address _pool) view returns(uint256[2])
func (_Curvefi *CurvefiCaller) GetFees(opts *bind.CallOpts, _pool common.Address) ([2]*big.Int, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "get_fees", _pool)
if err != nil {
return *new([2]*big.Int), err
}
out0 := *abi.ConvertType(out[0], new([2]*big.Int)).(*[2]*big.Int)
return out0, err
}
// GetFees is a free data retrieval call binding the contract method 0x7cdb72b0.
//
// Solidity: function get_fees(address _pool) view returns(uint256[2])
func (_Curvefi *CurvefiSession) GetFees(_pool common.Address) ([2]*big.Int, error) {
return _Curvefi.Contract.GetFees(&_Curvefi.CallOpts, _pool)
}
// GetFees is a free data retrieval call binding the contract method 0x7cdb72b0.
//
// Solidity: function get_fees(address _pool) view returns(uint256[2])
func (_Curvefi *CurvefiCallerSession) GetFees(_pool common.Address) ([2]*big.Int, error) {
return _Curvefi.Contract.GetFees(&_Curvefi.CallOpts, _pool)
}
// GetGauges is a free data retrieval call binding the contract method 0x56059ffb.
//
// Solidity: function get_gauges(address _pool) view returns(address[10], int128[10])
func (_Curvefi *CurvefiCaller) GetGauges(opts *bind.CallOpts, _pool common.Address) ([10]common.Address, [10]*big.Int, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "get_gauges", _pool)
if err != nil {
return *new([10]common.Address), *new([10]*big.Int), err
}
out0 := *abi.ConvertType(out[0], new([10]common.Address)).(*[10]common.Address)
out1 := *abi.ConvertType(out[1], new([10]*big.Int)).(*[10]*big.Int)
return out0, out1, err
}
// GetGauges is a free data retrieval call binding the contract method 0x56059ffb.
//
// Solidity: function get_gauges(address _pool) view returns(address[10], int128[10])
func (_Curvefi *CurvefiSession) GetGauges(_pool common.Address) ([10]common.Address, [10]*big.Int, error) {
return _Curvefi.Contract.GetGauges(&_Curvefi.CallOpts, _pool)
}
// GetGauges is a free data retrieval call binding the contract method 0x56059ffb.
//
// Solidity: function get_gauges(address _pool) view returns(address[10], int128[10])
func (_Curvefi *CurvefiCallerSession) GetGauges(_pool common.Address) ([10]common.Address, [10]*big.Int, error) {
return _Curvefi.Contract.GetGauges(&_Curvefi.CallOpts, _pool)
}
// GetLpToken is a free data retrieval call binding the contract method 0x37951049.
//
// Solidity: function get_lp_token(address arg0) view returns(address)
func (_Curvefi *CurvefiCaller) GetLpToken(opts *bind.CallOpts, arg0 common.Address) (common.Address, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "get_lp_token", arg0)
if err != nil {
return *new(common.Address), err
}
out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
return out0, err
}
// GetLpToken is a free data retrieval call binding the contract method 0x37951049.
//
// Solidity: function get_lp_token(address arg0) view returns(address)
func (_Curvefi *CurvefiSession) GetLpToken(arg0 common.Address) (common.Address, error) {
return _Curvefi.Contract.GetLpToken(&_Curvefi.CallOpts, arg0)
}
// GetLpToken is a free data retrieval call binding the contract method 0x37951049.
//
// Solidity: function get_lp_token(address arg0) view returns(address)
func (_Curvefi *CurvefiCallerSession) GetLpToken(arg0 common.Address) (common.Address, error) {
return _Curvefi.Contract.GetLpToken(&_Curvefi.CallOpts, arg0)
}
// GetNCoins is a free data retrieval call binding the contract method 0x940494f1.
//
// Solidity: function get_n_coins(address _pool) view returns(uint256[2])
func (_Curvefi *CurvefiCaller) GetNCoins(opts *bind.CallOpts, _pool common.Address) ([2]*big.Int, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "get_n_coins", _pool)
if err != nil {
return *new([2]*big.Int), err
}
out0 := *abi.ConvertType(out[0], new([2]*big.Int)).(*[2]*big.Int)
return out0, err
}
// GetNCoins is a free data retrieval call binding the contract method 0x940494f1.
//
// Solidity: function get_n_coins(address _pool) view returns(uint256[2])
func (_Curvefi *CurvefiSession) GetNCoins(_pool common.Address) ([2]*big.Int, error) {
return _Curvefi.Contract.GetNCoins(&_Curvefi.CallOpts, _pool)
}
// GetNCoins is a free data retrieval call binding the contract method 0x940494f1.
//
// Solidity: function get_n_coins(address _pool) view returns(uint256[2])
func (_Curvefi *CurvefiCallerSession) GetNCoins(_pool common.Address) ([2]*big.Int, error) {
return _Curvefi.Contract.GetNCoins(&_Curvefi.CallOpts, _pool)
}
// GetParameters is a free data retrieval call binding the contract method 0x1f80a957.
//
// Solidity: function get_parameters(address _pool) view returns(uint256 A, uint256 future_A, uint256 fee, uint256 admin_fee, uint256 future_fee, uint256 future_admin_fee, address future_owner, uint256 initial_A, uint256 initial_A_time, uint256 future_A_time)
func (_Curvefi *CurvefiCaller) GetParameters(opts *bind.CallOpts, _pool common.Address) (struct {
A *big.Int
FutureA *big.Int
Fee *big.Int
AdminFee *big.Int
FutureFee *big.Int
FutureAdminFee *big.Int
FutureOwner common.Address
InitialA *big.Int
InitialATime *big.Int
FutureATime *big.Int
}, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "get_parameters", _pool)
outstruct := new(struct {
A *big.Int
FutureA *big.Int
Fee *big.Int
AdminFee *big.Int
FutureFee *big.Int
FutureAdminFee *big.Int
FutureOwner common.Address
InitialA *big.Int
InitialATime *big.Int
FutureATime *big.Int
})
if err != nil {
return *outstruct, err
}
outstruct.A = *abi.ConvertType(out[0], new(*big.Int)).(**big.Int)
outstruct.FutureA = *abi.ConvertType(out[1], new(*big.Int)).(**big.Int)
outstruct.Fee = *abi.ConvertType(out[2], new(*big.Int)).(**big.Int)
outstruct.AdminFee = *abi.ConvertType(out[3], new(*big.Int)).(**big.Int)
outstruct.FutureFee = *abi.ConvertType(out[4], new(*big.Int)).(**big.Int)
outstruct.FutureAdminFee = *abi.ConvertType(out[5], new(*big.Int)).(**big.Int)
outstruct.FutureOwner = *abi.ConvertType(out[6], new(common.Address)).(*common.Address)
outstruct.InitialA = *abi.ConvertType(out[7], new(*big.Int)).(**big.Int)
outstruct.InitialATime = *abi.ConvertType(out[8], new(*big.Int)).(**big.Int)
outstruct.FutureATime = *abi.ConvertType(out[9], new(*big.Int)).(**big.Int)
return *outstruct, err
}
// GetParameters is a free data retrieval call binding the contract method 0x1f80a957.
//
// Solidity: function get_parameters(address _pool) view returns(uint256 A, uint256 future_A, uint256 fee, uint256 admin_fee, uint256 future_fee, uint256 future_admin_fee, address future_owner, uint256 initial_A, uint256 initial_A_time, uint256 future_A_time)
func (_Curvefi *CurvefiSession) GetParameters(_pool common.Address) (struct {
A *big.Int
FutureA *big.Int
Fee *big.Int
AdminFee *big.Int
FutureFee *big.Int
FutureAdminFee *big.Int
FutureOwner common.Address
InitialA *big.Int
InitialATime *big.Int
FutureATime *big.Int
}, error) {
return _Curvefi.Contract.GetParameters(&_Curvefi.CallOpts, _pool)
}
// GetParameters is a free data retrieval call binding the contract method 0x1f80a957.
//
// Solidity: function get_parameters(address _pool) view returns(uint256 A, uint256 future_A, uint256 fee, uint256 admin_fee, uint256 future_fee, uint256 future_admin_fee, address future_owner, uint256 initial_A, uint256 initial_A_time, uint256 future_A_time)
func (_Curvefi *CurvefiCallerSession) GetParameters(_pool common.Address) (struct {
A *big.Int
FutureA *big.Int
Fee *big.Int
AdminFee *big.Int
FutureFee *big.Int
FutureAdminFee *big.Int
FutureOwner common.Address
InitialA *big.Int
InitialATime *big.Int
FutureATime *big.Int
}, error) {
return _Curvefi.Contract.GetParameters(&_Curvefi.CallOpts, _pool)
}
// GetPoolAssetType is a free data retrieval call binding the contract method 0x66d3966c.
//
// Solidity: function get_pool_asset_type(address _pool) view returns(uint256)
func (_Curvefi *CurvefiCaller) GetPoolAssetType(opts *bind.CallOpts, _pool common.Address) (*big.Int, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "get_pool_asset_type", _pool)
if err != nil {
return *new(*big.Int), err
}
out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int)
return out0, err
}
// GetPoolAssetType is a free data retrieval call binding the contract method 0x66d3966c.
//
// Solidity: function get_pool_asset_type(address _pool) view returns(uint256)
func (_Curvefi *CurvefiSession) GetPoolAssetType(_pool common.Address) (*big.Int, error) {
return _Curvefi.Contract.GetPoolAssetType(&_Curvefi.CallOpts, _pool)
}
// GetPoolAssetType is a free data retrieval call binding the contract method 0x66d3966c.
//
// Solidity: function get_pool_asset_type(address _pool) view returns(uint256)
func (_Curvefi *CurvefiCallerSession) GetPoolAssetType(_pool common.Address) (*big.Int, error) {
return _Curvefi.Contract.GetPoolAssetType(&_Curvefi.CallOpts, _pool)
}
// GetPoolFromLpToken is a free data retrieval call binding the contract method 0xbdf475c3.
//
// Solidity: function get_pool_from_lp_token(address arg0) view returns(address)
func (_Curvefi *CurvefiCaller) GetPoolFromLpToken(opts *bind.CallOpts, arg0 common.Address) (common.Address, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "get_pool_from_lp_token", arg0)
if err != nil {
return *new(common.Address), err
}
out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
return out0, err
}
// GetPoolFromLpToken is a free data retrieval call binding the contract method 0xbdf475c3.
//
// Solidity: function get_pool_from_lp_token(address arg0) view returns(address)
func (_Curvefi *CurvefiSession) GetPoolFromLpToken(arg0 common.Address) (common.Address, error) {
return _Curvefi.Contract.GetPoolFromLpToken(&_Curvefi.CallOpts, arg0)
}
// GetPoolFromLpToken is a free data retrieval call binding the contract method 0xbdf475c3.
//
// Solidity: function get_pool_from_lp_token(address arg0) view returns(address)
func (_Curvefi *CurvefiCallerSession) GetPoolFromLpToken(arg0 common.Address) (common.Address, error) {
return _Curvefi.Contract.GetPoolFromLpToken(&_Curvefi.CallOpts, arg0)
}
// GetPoolName is a free data retrieval call binding the contract method 0x5c911741.
//
// Solidity: function get_pool_name(address _pool) view returns(string)
func (_Curvefi *CurvefiCaller) GetPoolName(opts *bind.CallOpts, _pool common.Address) (string, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "get_pool_name", _pool)
if err != nil {
return *new(string), err
}
out0 := *abi.ConvertType(out[0], new(string)).(*string)
return out0, err
}
// GetPoolName is a free data retrieval call binding the contract method 0x5c911741.
//
// Solidity: function get_pool_name(address _pool) view returns(string)
func (_Curvefi *CurvefiSession) GetPoolName(_pool common.Address) (string, error) {
return _Curvefi.Contract.GetPoolName(&_Curvefi.CallOpts, _pool)
}
// GetPoolName is a free data retrieval call binding the contract method 0x5c911741.
//
// Solidity: function get_pool_name(address _pool) view returns(string)
func (_Curvefi *CurvefiCallerSession) GetPoolName(_pool common.Address) (string, error) {
return _Curvefi.Contract.GetPoolName(&_Curvefi.CallOpts, _pool)
}
// GetRates is a free data retrieval call binding the contract method 0xce99e45a.
//
// Solidity: function get_rates(address _pool) view returns(uint256[8])
func (_Curvefi *CurvefiCaller) GetRates(opts *bind.CallOpts, _pool common.Address) ([8]*big.Int, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "get_rates", _pool)
if err != nil {
return *new([8]*big.Int), err
}
out0 := *abi.ConvertType(out[0], new([8]*big.Int)).(*[8]*big.Int)
return out0, err
}
// GetRates is a free data retrieval call binding the contract method 0xce99e45a.
//
// Solidity: function get_rates(address _pool) view returns(uint256[8])
func (_Curvefi *CurvefiSession) GetRates(_pool common.Address) ([8]*big.Int, error) {
return _Curvefi.Contract.GetRates(&_Curvefi.CallOpts, _pool)
}
// GetRates is a free data retrieval call binding the contract method 0xce99e45a.
//
// Solidity: function get_rates(address _pool) view returns(uint256[8])
func (_Curvefi *CurvefiCallerSession) GetRates(_pool common.Address) ([8]*big.Int, error) {
return _Curvefi.Contract.GetRates(&_Curvefi.CallOpts, _pool)
}
// GetUnderlyingBalances is a free data retrieval call binding the contract method 0x59f4f351.
//
// Solidity: function get_underlying_balances(address _pool) view returns(uint256[8])
func (_Curvefi *CurvefiCaller) GetUnderlyingBalances(opts *bind.CallOpts, _pool common.Address) ([8]*big.Int, error) {
var out []interface{}
err := _Curvefi.contract.Call(opts, &out, "get_underlying_balances", _pool)
if err != nil {
return *new([8]*big.Int), err
}
out0 := *abi.ConvertType(out[0], new([8]*big.Int)).(*[8]*big.Int)
return out0, err
}
// GetUnderlyingBalances is a free data retrieval call binding the contract method 0x59f4f351.