123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497 |
- // Code generated - DO NOT EDIT.
- // This file is a generated binding and any manual changes will be lost.
- package Collect
- 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
- )
- // CollectMetaData contains all meta data concerning the Collect contract.
- var CollectMetaData = &bind.MetaData{
- ABI: "[{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"signature\",\"type\":\"bytes32\"}],\"name\":\"Claim\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"claimValue\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"signTime\",\"type\":\"string\"},{\"internalType\":\"bytes32\",\"name\":\"signature\",\"type\":\"bytes32\"}],\"name\":\"claimRewards\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"initialize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"community\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"technical\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"devAddress\",\"type\":\"address\"}],\"name\":\"initialize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"previousOwner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"OwnershipTransferred\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"inviter\",\"type\":\"address\"}],\"name\":\"participate\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"participant\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"inviter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"Participate\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_manager\",\"type\":\"address\"}],\"name\":\"removeManager\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"_manager\",\"type\":\"address\"}],\"name\":\"RemoveManager\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"baseReward\",\"type\":\"uint256\"}],\"name\":\"setBaseReward\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setBaseValue\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_digit\",\"type\":\"string\"}],\"name\":\"setDigit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_manager\",\"type\":\"address\"}],\"name\":\"setManager\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"_manager\",\"type\":\"address\"}],\"name\":\"SetManager\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"withdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"_baseReward\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"_baseValue\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"_community\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"_devAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"_reinputLimit\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"_reinputModBase\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"_technical\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDigit\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"managers\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"signTime\",\"type\":\"string\"},{\"internalType\":\"bytes32\",\"name\":\"signature\",\"type\":\"bytes32\"}],\"name\":\"verify\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"_time\",\"type\":\"string\"},{\"internalType\":\"address\",\"name\":\"_user\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"_sign\",\"type\":\"bytes32\"}],\"name\":\"verifySignature\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]",
- }
- // CollectABI is the input ABI used to generate the binding from.
- // Deprecated: Use CollectMetaData.ABI instead.
- var CollectABI = CollectMetaData.ABI
- // Collect is an auto generated Go binding around an Ethereum contract.
- type Collect struct {
- CollectCaller // Read-only binding to the contract
- CollectTransactor // Write-only binding to the contract
- CollectFilterer // Log filterer for contract events
- }
- // CollectCaller is an auto generated read-only Go binding around an Ethereum contract.
- type CollectCaller struct {
- contract *bind.BoundContract // Generic contract wrapper for the low level calls
- }
- // CollectTransactor is an auto generated write-only Go binding around an Ethereum contract.
- type CollectTransactor struct {
- contract *bind.BoundContract // Generic contract wrapper for the low level calls
- }
- // CollectFilterer is an auto generated log filtering Go binding around an Ethereum contract events.
- type CollectFilterer struct {
- contract *bind.BoundContract // Generic contract wrapper for the low level calls
- }
- // CollectSession is an auto generated Go binding around an Ethereum contract,
- // with pre-set call and transact options.
- type CollectSession struct {
- Contract *Collect // 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
- }
- // CollectCallerSession is an auto generated read-only Go binding around an Ethereum contract,
- // with pre-set call options.
- type CollectCallerSession struct {
- Contract *CollectCaller // Generic contract caller binding to set the session for
- CallOpts bind.CallOpts // Call options to use throughout this session
- }
- // CollectTransactorSession is an auto generated write-only Go binding around an Ethereum contract,
- // with pre-set transact options.
- type CollectTransactorSession struct {
- Contract *CollectTransactor // Generic contract transactor binding to set the session for
- TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session
- }
- // CollectRaw is an auto generated low-level Go binding around an Ethereum contract.
- type CollectRaw struct {
- Contract *Collect // Generic contract binding to access the raw methods on
- }
- // CollectCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract.
- type CollectCallerRaw struct {
- Contract *CollectCaller // Generic read-only contract binding to access the raw methods on
- }
- // CollectTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract.
- type CollectTransactorRaw struct {
- Contract *CollectTransactor // Generic write-only contract binding to access the raw methods on
- }
- // NewCollect creates a new instance of Collect, bound to a specific deployed contract.
- func NewCollect(address common.Address, backend bind.ContractBackend) (*Collect, error) {
- contract, err := bindCollect(address, backend, backend, backend)
- if err != nil {
- return nil, err
- }
- return &Collect{CollectCaller: CollectCaller{contract: contract}, CollectTransactor: CollectTransactor{contract: contract}, CollectFilterer: CollectFilterer{contract: contract}}, nil
- }
- // NewCollectCaller creates a new read-only instance of Collect, bound to a specific deployed contract.
- func NewCollectCaller(address common.Address, caller bind.ContractCaller) (*CollectCaller, error) {
- contract, err := bindCollect(address, caller, nil, nil)
- if err != nil {
- return nil, err
- }
- return &CollectCaller{contract: contract}, nil
- }
- // NewCollectTransactor creates a new write-only instance of Collect, bound to a specific deployed contract.
- func NewCollectTransactor(address common.Address, transactor bind.ContractTransactor) (*CollectTransactor, error) {
- contract, err := bindCollect(address, nil, transactor, nil)
- if err != nil {
- return nil, err
- }
- return &CollectTransactor{contract: contract}, nil
- }
- // NewCollectFilterer creates a new log filterer instance of Collect, bound to a specific deployed contract.
- func NewCollectFilterer(address common.Address, filterer bind.ContractFilterer) (*CollectFilterer, error) {
- contract, err := bindCollect(address, nil, nil, filterer)
- if err != nil {
- return nil, err
- }
- return &CollectFilterer{contract: contract}, nil
- }
- // bindCollect binds a generic wrapper to an already deployed contract.
- func bindCollect(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) {
- parsed, err := abi.JSON(strings.NewReader(CollectABI))
- 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 (_Collect *CollectRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error {
- return _Collect.Contract.CollectCaller.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 (_Collect *CollectRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) {
- return _Collect.Contract.CollectTransactor.contract.Transfer(opts)
- }
- // Transact invokes the (paid) contract method with params as input values.
- func (_Collect *CollectRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) {
- return _Collect.Contract.CollectTransactor.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 (_Collect *CollectCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error {
- return _Collect.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 (_Collect *CollectTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) {
- return _Collect.Contract.contract.Transfer(opts)
- }
- // Transact invokes the (paid) contract method with params as input values.
- func (_Collect *CollectTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) {
- return _Collect.Contract.contract.Transact(opts, method, params...)
- }
- // BaseReward is a free data retrieval call binding the contract method 0xb0c466d8.
- //
- // Solidity: function _baseReward() view returns(uint256)
- func (_Collect *CollectCaller) BaseReward(opts *bind.CallOpts) (*big.Int, error) {
- var out []interface{}
- err := _Collect.contract.Call(opts, &out, "_baseReward")
- if err != nil {
- return *new(*big.Int), err
- }
- out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int)
- return out0, err
- }
- // BaseReward is a free data retrieval call binding the contract method 0xb0c466d8.
- //
- // Solidity: function _baseReward() view returns(uint256)
- func (_Collect *CollectSession) BaseReward() (*big.Int, error) {
- return _Collect.Contract.BaseReward(&_Collect.CallOpts)
- }
- // BaseReward is a free data retrieval call binding the contract method 0xb0c466d8.
- //
- // Solidity: function _baseReward() view returns(uint256)
- func (_Collect *CollectCallerSession) BaseReward() (*big.Int, error) {
- return _Collect.Contract.BaseReward(&_Collect.CallOpts)
- }
- // BaseValue is a free data retrieval call binding the contract method 0x138efbaf.
- //
- // Solidity: function _baseValue() view returns(uint256)
- func (_Collect *CollectCaller) BaseValue(opts *bind.CallOpts) (*big.Int, error) {
- var out []interface{}
- err := _Collect.contract.Call(opts, &out, "_baseValue")
- if err != nil {
- return *new(*big.Int), err
- }
- out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int)
- return out0, err
- }
- // BaseValue is a free data retrieval call binding the contract method 0x138efbaf.
- //
- // Solidity: function _baseValue() view returns(uint256)
- func (_Collect *CollectSession) BaseValue() (*big.Int, error) {
- return _Collect.Contract.BaseValue(&_Collect.CallOpts)
- }
- // BaseValue is a free data retrieval call binding the contract method 0x138efbaf.
- //
- // Solidity: function _baseValue() view returns(uint256)
- func (_Collect *CollectCallerSession) BaseValue() (*big.Int, error) {
- return _Collect.Contract.BaseValue(&_Collect.CallOpts)
- }
- // Community is a free data retrieval call binding the contract method 0x723bc11a.
- //
- // Solidity: function _community() view returns(address)
- func (_Collect *CollectCaller) Community(opts *bind.CallOpts) (common.Address, error) {
- var out []interface{}
- err := _Collect.contract.Call(opts, &out, "_community")
- if err != nil {
- return *new(common.Address), err
- }
- out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
- return out0, err
- }
- // Community is a free data retrieval call binding the contract method 0x723bc11a.
- //
- // Solidity: function _community() view returns(address)
- func (_Collect *CollectSession) Community() (common.Address, error) {
- return _Collect.Contract.Community(&_Collect.CallOpts)
- }
- // Community is a free data retrieval call binding the contract method 0x723bc11a.
- //
- // Solidity: function _community() view returns(address)
- func (_Collect *CollectCallerSession) Community() (common.Address, error) {
- return _Collect.Contract.Community(&_Collect.CallOpts)
- }
- // DevAddress is a free data retrieval call binding the contract method 0x6af65929.
- //
- // Solidity: function _devAddress() view returns(address)
- func (_Collect *CollectCaller) DevAddress(opts *bind.CallOpts) (common.Address, error) {
- var out []interface{}
- err := _Collect.contract.Call(opts, &out, "_devAddress")
- if err != nil {
- return *new(common.Address), err
- }
- out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
- return out0, err
- }
- // DevAddress is a free data retrieval call binding the contract method 0x6af65929.
- //
- // Solidity: function _devAddress() view returns(address)
- func (_Collect *CollectSession) DevAddress() (common.Address, error) {
- return _Collect.Contract.DevAddress(&_Collect.CallOpts)
- }
- // DevAddress is a free data retrieval call binding the contract method 0x6af65929.
- //
- // Solidity: function _devAddress() view returns(address)
- func (_Collect *CollectCallerSession) DevAddress() (common.Address, error) {
- return _Collect.Contract.DevAddress(&_Collect.CallOpts)
- }
- // ReinputLimit is a free data retrieval call binding the contract method 0xe975e999.
- //
- // Solidity: function _reinputLimit() view returns(uint256)
- func (_Collect *CollectCaller) ReinputLimit(opts *bind.CallOpts) (*big.Int, error) {
- var out []interface{}
- err := _Collect.contract.Call(opts, &out, "_reinputLimit")
- if err != nil {
- return *new(*big.Int), err
- }
- out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int)
- return out0, err
- }
- // ReinputLimit is a free data retrieval call binding the contract method 0xe975e999.
- //
- // Solidity: function _reinputLimit() view returns(uint256)
- func (_Collect *CollectSession) ReinputLimit() (*big.Int, error) {
- return _Collect.Contract.ReinputLimit(&_Collect.CallOpts)
- }
- // ReinputLimit is a free data retrieval call binding the contract method 0xe975e999.
- //
- // Solidity: function _reinputLimit() view returns(uint256)
- func (_Collect *CollectCallerSession) ReinputLimit() (*big.Int, error) {
- return _Collect.Contract.ReinputLimit(&_Collect.CallOpts)
- }
- // ReinputModBase is a free data retrieval call binding the contract method 0xf517767f.
- //
- // Solidity: function _reinputModBase() view returns(uint256)
- func (_Collect *CollectCaller) ReinputModBase(opts *bind.CallOpts) (*big.Int, error) {
- var out []interface{}
- err := _Collect.contract.Call(opts, &out, "_reinputModBase")
- if err != nil {
- return *new(*big.Int), err
- }
- out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int)
- return out0, err
- }
- // ReinputModBase is a free data retrieval call binding the contract method 0xf517767f.
- //
- // Solidity: function _reinputModBase() view returns(uint256)
- func (_Collect *CollectSession) ReinputModBase() (*big.Int, error) {
- return _Collect.Contract.ReinputModBase(&_Collect.CallOpts)
- }
- // ReinputModBase is a free data retrieval call binding the contract method 0xf517767f.
- //
- // Solidity: function _reinputModBase() view returns(uint256)
- func (_Collect *CollectCallerSession) ReinputModBase() (*big.Int, error) {
- return _Collect.Contract.ReinputModBase(&_Collect.CallOpts)
- }
- // Technical is a free data retrieval call binding the contract method 0x37a56907.
- //
- // Solidity: function _technical() view returns(address)
- func (_Collect *CollectCaller) Technical(opts *bind.CallOpts) (common.Address, error) {
- var out []interface{}
- err := _Collect.contract.Call(opts, &out, "_technical")
- if err != nil {
- return *new(common.Address), err
- }
- out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
- return out0, err
- }
- // Technical is a free data retrieval call binding the contract method 0x37a56907.
- //
- // Solidity: function _technical() view returns(address)
- func (_Collect *CollectSession) Technical() (common.Address, error) {
- return _Collect.Contract.Technical(&_Collect.CallOpts)
- }
- // Technical is a free data retrieval call binding the contract method 0x37a56907.
- //
- // Solidity: function _technical() view returns(address)
- func (_Collect *CollectCallerSession) Technical() (common.Address, error) {
- return _Collect.Contract.Technical(&_Collect.CallOpts)
- }
- // GetDigit is a free data retrieval call binding the contract method 0x6b590248.
- //
- // Solidity: function getDigit() view returns(string)
- func (_Collect *CollectCaller) GetDigit(opts *bind.CallOpts) (string, error) {
- var out []interface{}
- err := _Collect.contract.Call(opts, &out, "getDigit")
- if err != nil {
- return *new(string), err
- }
- out0 := *abi.ConvertType(out[0], new(string)).(*string)
- return out0, err
- }
- // GetDigit is a free data retrieval call binding the contract method 0x6b590248.
- //
- // Solidity: function getDigit() view returns(string)
- func (_Collect *CollectSession) GetDigit() (string, error) {
- return _Collect.Contract.GetDigit(&_Collect.CallOpts)
- }
- // GetDigit is a free data retrieval call binding the contract method 0x6b590248.
- //
- // Solidity: function getDigit() view returns(string)
- func (_Collect *CollectCallerSession) GetDigit() (string, error) {
- return _Collect.Contract.GetDigit(&_Collect.CallOpts)
- }
- // Managers is a free data retrieval call binding the contract method 0xfdff9b4d.
- //
- // Solidity: function managers(address ) view returns(bool)
- func (_Collect *CollectCaller) Managers(opts *bind.CallOpts, arg0 common.Address) (bool, error) {
- var out []interface{}
- err := _Collect.contract.Call(opts, &out, "managers", arg0)
- if err != nil {
- return *new(bool), err
- }
- out0 := *abi.ConvertType(out[0], new(bool)).(*bool)
- return out0, err
- }
- // Managers is a free data retrieval call binding the contract method 0xfdff9b4d.
- //
- // Solidity: function managers(address ) view returns(bool)
- func (_Collect *CollectSession) Managers(arg0 common.Address) (bool, error) {
- return _Collect.Contract.Managers(&_Collect.CallOpts, arg0)
- }
- // Managers is a free data retrieval call binding the contract method 0xfdff9b4d.
- //
- // Solidity: function managers(address ) view returns(bool)
- func (_Collect *CollectCallerSession) Managers(arg0 common.Address) (bool, error) {
- return _Collect.Contract.Managers(&_Collect.CallOpts, arg0)
- }
- // Owner is a free data retrieval call binding the contract method 0x8da5cb5b.
- //
- // Solidity: function owner() view returns(address)
- func (_Collect *CollectCaller) Owner(opts *bind.CallOpts) (common.Address, error) {
- var out []interface{}
- err := _Collect.contract.Call(opts, &out, "owner")
- if err != nil {
- return *new(common.Address), err
- }
- out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
- return out0, err
- }
- // Owner is a free data retrieval call binding the contract method 0x8da5cb5b.
- //
- // Solidity: function owner() view returns(address)
- func (_Collect *CollectSession) Owner() (common.Address, error) {
- return _Collect.Contract.Owner(&_Collect.CallOpts)
- }
- // Owner is a free data retrieval call binding the contract method 0x8da5cb5b.
- //
- // Solidity: function owner() view returns(address)
- func (_Collect *CollectCallerSession) Owner() (common.Address, error) {
- return _Collect.Contract.Owner(&_Collect.CallOpts)
- }
- // Verify is a free data retrieval call binding the contract method 0x6cd80733.
- //
- // Solidity: function verify(uint256 amount, string signTime, bytes32 signature) view returns(bool)
- func (_Collect *CollectCaller) Verify(opts *bind.CallOpts, amount *big.Int, signTime string, signature [32]byte) (bool, error) {
- var out []interface{}
- err := _Collect.contract.Call(opts, &out, "verify", amount, signTime, signature)
- if err != nil {
- return *new(bool), err
- }
- out0 := *abi.ConvertType(out[0], new(bool)).(*bool)
- return out0, err
- }
- // Verify is a free data retrieval call binding the contract method 0x6cd80733.
- //
- // Solidity: function verify(uint256 amount, string signTime, bytes32 signature) view returns(bool)
- func (_Collect *CollectSession) Verify(amount *big.Int, signTime string, signature [32]byte) (bool, error) {
- return _Collect.Contract.Verify(&_Collect.CallOpts, amount, signTime, signature)
- }
- // Verify is a free data retrieval call binding the contract method 0x6cd80733.
- //
- // Solidity: function verify(uint256 amount, string signTime, bytes32 signature) view returns(bool)
- func (_Collect *CollectCallerSession) Verify(amount *big.Int, signTime string, signature [32]byte) (bool, error) {
- return _Collect.Contract.Verify(&_Collect.CallOpts, amount, signTime, signature)
- }
- // VerifySignature is a free data retrieval call binding the contract method 0x19ba5284.
- //
- // Solidity: function verifySignature(uint256 _amount, string _time, address _user, bytes32 _sign) view returns(bool)
- func (_Collect *CollectCaller) VerifySignature(opts *bind.CallOpts, _amount *big.Int, _time string, _user common.Address, _sign [32]byte) (bool, error) {
- var out []interface{}
- err := _Collect.contract.Call(opts, &out, "verifySignature", _amount, _time, _user, _sign)
- if err != nil {
- return *new(bool), err
- }
- out0 := *abi.ConvertType(out[0], new(bool)).(*bool)
- return out0, err
- }
- // VerifySignature is a free data retrieval call binding the contract method 0x19ba5284.
- //
- // Solidity: function verifySignature(uint256 _amount, string _time, address _user, bytes32 _sign) view returns(bool)
- func (_Collect *CollectSession) VerifySignature(_amount *big.Int, _time string, _user common.Address, _sign [32]byte) (bool, error) {
- return _Collect.Contract.VerifySignature(&_Collect.CallOpts, _amount, _time, _user, _sign)
- }
- // VerifySignature is a free data retrieval call binding the contract method 0x19ba5284.
- //
- // Solidity: function verifySignature(uint256 _amount, string _time, address _user, bytes32 _sign) view returns(bool)
- func (_Collect *CollectCallerSession) VerifySignature(_amount *big.Int, _time string, _user common.Address, _sign [32]byte) (bool, error) {
- return _Collect.Contract.VerifySignature(&_Collect.CallOpts, _amount, _time, _user, _sign)
- }
- // ClaimRewards is a paid mutator transaction binding the contract method 0xd56099aa.
- //
- // Solidity: function claimRewards(uint256 claimValue, string signTime, bytes32 signature) returns()
- func (_Collect *CollectTransactor) ClaimRewards(opts *bind.TransactOpts, claimValue *big.Int, signTime string, signature [32]byte) (*types.Transaction, error) {
- return _Collect.contract.Transact(opts, "claimRewards", claimValue, signTime, signature)
- }
- // ClaimRewards is a paid mutator transaction binding the contract method 0xd56099aa.
- //
- // Solidity: function claimRewards(uint256 claimValue, string signTime, bytes32 signature) returns()
- func (_Collect *CollectSession) ClaimRewards(claimValue *big.Int, signTime string, signature [32]byte) (*types.Transaction, error) {
- return _Collect.Contract.ClaimRewards(&_Collect.TransactOpts, claimValue, signTime, signature)
- }
- // ClaimRewards is a paid mutator transaction binding the contract method 0xd56099aa.
- //
- // Solidity: function claimRewards(uint256 claimValue, string signTime, bytes32 signature) returns()
- func (_Collect *CollectTransactorSession) ClaimRewards(claimValue *big.Int, signTime string, signature [32]byte) (*types.Transaction, error) {
- return _Collect.Contract.ClaimRewards(&_Collect.TransactOpts, claimValue, signTime, signature)
- }
- // Initialize is a paid mutator transaction binding the contract method 0x8129fc1c.
- //
- // Solidity: function initialize() returns()
- func (_Collect *CollectTransactor) Initialize(opts *bind.TransactOpts) (*types.Transaction, error) {
- return _Collect.contract.Transact(opts, "initialize")
- }
- // Initialize is a paid mutator transaction binding the contract method 0x8129fc1c.
- //
- // Solidity: function initialize() returns()
- func (_Collect *CollectSession) Initialize() (*types.Transaction, error) {
- return _Collect.Contract.Initialize(&_Collect.TransactOpts)
- }
- // Initialize is a paid mutator transaction binding the contract method 0x8129fc1c.
- //
- // Solidity: function initialize() returns()
- func (_Collect *CollectTransactorSession) Initialize() (*types.Transaction, error) {
- return _Collect.Contract.Initialize(&_Collect.TransactOpts)
- }
- // Initialize0 is a paid mutator transaction binding the contract method 0xc0c53b8b.
- //
- // Solidity: function initialize(address community, address technical, address devAddress) returns()
- func (_Collect *CollectTransactor) Initialize0(opts *bind.TransactOpts, community common.Address, technical common.Address, devAddress common.Address) (*types.Transaction, error) {
- return _Collect.contract.Transact(opts, "initialize0", community, technical, devAddress)
- }
- // Initialize0 is a paid mutator transaction binding the contract method 0xc0c53b8b.
- //
- // Solidity: function initialize(address community, address technical, address devAddress) returns()
- func (_Collect *CollectSession) Initialize0(community common.Address, technical common.Address, devAddress common.Address) (*types.Transaction, error) {
- return _Collect.Contract.Initialize0(&_Collect.TransactOpts, community, technical, devAddress)
- }
- // Initialize0 is a paid mutator transaction binding the contract method 0xc0c53b8b.
- //
- // Solidity: function initialize(address community, address technical, address devAddress) returns()
- func (_Collect *CollectTransactorSession) Initialize0(community common.Address, technical common.Address, devAddress common.Address) (*types.Transaction, error) {
- return _Collect.Contract.Initialize0(&_Collect.TransactOpts, community, technical, devAddress)
- }
- // Participate is a paid mutator transaction binding the contract method 0xb91038c7.
- //
- // Solidity: function participate(address inviter) payable returns()
- func (_Collect *CollectTransactor) Participate(opts *bind.TransactOpts, inviter common.Address) (*types.Transaction, error) {
- return _Collect.contract.Transact(opts, "participate", inviter)
- }
- // Participate is a paid mutator transaction binding the contract method 0xb91038c7.
- //
- // Solidity: function participate(address inviter) payable returns()
- func (_Collect *CollectSession) Participate(inviter common.Address) (*types.Transaction, error) {
- return _Collect.Contract.Participate(&_Collect.TransactOpts, inviter)
- }
- // Participate is a paid mutator transaction binding the contract method 0xb91038c7.
- //
- // Solidity: function participate(address inviter) payable returns()
- func (_Collect *CollectTransactorSession) Participate(inviter common.Address) (*types.Transaction, error) {
- return _Collect.Contract.Participate(&_Collect.TransactOpts, inviter)
- }
- // RemoveManager is a paid mutator transaction binding the contract method 0xac18de43.
- //
- // Solidity: function removeManager(address _manager) returns()
- func (_Collect *CollectTransactor) RemoveManager(opts *bind.TransactOpts, _manager common.Address) (*types.Transaction, error) {
- return _Collect.contract.Transact(opts, "removeManager", _manager)
- }
- // RemoveManager is a paid mutator transaction binding the contract method 0xac18de43.
- //
- // Solidity: function removeManager(address _manager) returns()
- func (_Collect *CollectSession) RemoveManager(_manager common.Address) (*types.Transaction, error) {
- return _Collect.Contract.RemoveManager(&_Collect.TransactOpts, _manager)
- }
- // RemoveManager is a paid mutator transaction binding the contract method 0xac18de43.
- //
- // Solidity: function removeManager(address _manager) returns()
- func (_Collect *CollectTransactorSession) RemoveManager(_manager common.Address) (*types.Transaction, error) {
- return _Collect.Contract.RemoveManager(&_Collect.TransactOpts, _manager)
- }
- // RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6.
- //
- // Solidity: function renounceOwnership() returns()
- func (_Collect *CollectTransactor) RenounceOwnership(opts *bind.TransactOpts) (*types.Transaction, error) {
- return _Collect.contract.Transact(opts, "renounceOwnership")
- }
- // RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6.
- //
- // Solidity: function renounceOwnership() returns()
- func (_Collect *CollectSession) RenounceOwnership() (*types.Transaction, error) {
- return _Collect.Contract.RenounceOwnership(&_Collect.TransactOpts)
- }
- // RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6.
- //
- // Solidity: function renounceOwnership() returns()
- func (_Collect *CollectTransactorSession) RenounceOwnership() (*types.Transaction, error) {
- return _Collect.Contract.RenounceOwnership(&_Collect.TransactOpts)
- }
- // SetBaseReward is a paid mutator transaction binding the contract method 0x0373a23a.
- //
- // Solidity: function setBaseReward(uint256 baseReward) returns()
- func (_Collect *CollectTransactor) SetBaseReward(opts *bind.TransactOpts, baseReward *big.Int) (*types.Transaction, error) {
- return _Collect.contract.Transact(opts, "setBaseReward", baseReward)
- }
- // SetBaseReward is a paid mutator transaction binding the contract method 0x0373a23a.
- //
- // Solidity: function setBaseReward(uint256 baseReward) returns()
- func (_Collect *CollectSession) SetBaseReward(baseReward *big.Int) (*types.Transaction, error) {
- return _Collect.Contract.SetBaseReward(&_Collect.TransactOpts, baseReward)
- }
- // SetBaseReward is a paid mutator transaction binding the contract method 0x0373a23a.
- //
- // Solidity: function setBaseReward(uint256 baseReward) returns()
- func (_Collect *CollectTransactorSession) SetBaseReward(baseReward *big.Int) (*types.Transaction, error) {
- return _Collect.Contract.SetBaseReward(&_Collect.TransactOpts, baseReward)
- }
- // SetBaseValue is a paid mutator transaction binding the contract method 0x3faf24a1.
- //
- // Solidity: function setBaseValue(uint256 value) returns()
- func (_Collect *CollectTransactor) SetBaseValue(opts *bind.TransactOpts, value *big.Int) (*types.Transaction, error) {
- return _Collect.contract.Transact(opts, "setBaseValue", value)
- }
- // SetBaseValue is a paid mutator transaction binding the contract method 0x3faf24a1.
- //
- // Solidity: function setBaseValue(uint256 value) returns()
- func (_Collect *CollectSession) SetBaseValue(value *big.Int) (*types.Transaction, error) {
- return _Collect.Contract.SetBaseValue(&_Collect.TransactOpts, value)
- }
- // SetBaseValue is a paid mutator transaction binding the contract method 0x3faf24a1.
- //
- // Solidity: function setBaseValue(uint256 value) returns()
- func (_Collect *CollectTransactorSession) SetBaseValue(value *big.Int) (*types.Transaction, error) {
- return _Collect.Contract.SetBaseValue(&_Collect.TransactOpts, value)
- }
- // SetDigit is a paid mutator transaction binding the contract method 0x4dbfaecf.
- //
- // Solidity: function setDigit(string _digit) returns()
- func (_Collect *CollectTransactor) SetDigit(opts *bind.TransactOpts, _digit string) (*types.Transaction, error) {
- return _Collect.contract.Transact(opts, "setDigit", _digit)
- }
- // SetDigit is a paid mutator transaction binding the contract method 0x4dbfaecf.
- //
- // Solidity: function setDigit(string _digit) returns()
- func (_Collect *CollectSession) SetDigit(_digit string) (*types.Transaction, error) {
- return _Collect.Contract.SetDigit(&_Collect.TransactOpts, _digit)
- }
- // SetDigit is a paid mutator transaction binding the contract method 0x4dbfaecf.
- //
- // Solidity: function setDigit(string _digit) returns()
- func (_Collect *CollectTransactorSession) SetDigit(_digit string) (*types.Transaction, error) {
- return _Collect.Contract.SetDigit(&_Collect.TransactOpts, _digit)
- }
- // SetManager is a paid mutator transaction binding the contract method 0xd0ebdbe7.
- //
- // Solidity: function setManager(address _manager) returns()
- func (_Collect *CollectTransactor) SetManager(opts *bind.TransactOpts, _manager common.Address) (*types.Transaction, error) {
- return _Collect.contract.Transact(opts, "setManager", _manager)
- }
- // SetManager is a paid mutator transaction binding the contract method 0xd0ebdbe7.
- //
- // Solidity: function setManager(address _manager) returns()
- func (_Collect *CollectSession) SetManager(_manager common.Address) (*types.Transaction, error) {
- return _Collect.Contract.SetManager(&_Collect.TransactOpts, _manager)
- }
- // SetManager is a paid mutator transaction binding the contract method 0xd0ebdbe7.
- //
- // Solidity: function setManager(address _manager) returns()
- func (_Collect *CollectTransactorSession) SetManager(_manager common.Address) (*types.Transaction, error) {
- return _Collect.Contract.SetManager(&_Collect.TransactOpts, _manager)
- }
- // TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b.
- //
- // Solidity: function transferOwnership(address newOwner) returns()
- func (_Collect *CollectTransactor) TransferOwnership(opts *bind.TransactOpts, newOwner common.Address) (*types.Transaction, error) {
- return _Collect.contract.Transact(opts, "transferOwnership", newOwner)
- }
- // TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b.
- //
- // Solidity: function transferOwnership(address newOwner) returns()
- func (_Collect *CollectSession) TransferOwnership(newOwner common.Address) (*types.Transaction, error) {
- return _Collect.Contract.TransferOwnership(&_Collect.TransactOpts, newOwner)
- }
- // TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b.
- //
- // Solidity: function transferOwnership(address newOwner) returns()
- func (_Collect *CollectTransactorSession) TransferOwnership(newOwner common.Address) (*types.Transaction, error) {
- return _Collect.Contract.TransferOwnership(&_Collect.TransactOpts, newOwner)
- }
- // Withdraw is a paid mutator transaction binding the contract method 0x2e1a7d4d.
- //
- // Solidity: function withdraw(uint256 amount) returns()
- func (_Collect *CollectTransactor) Withdraw(opts *bind.TransactOpts, amount *big.Int) (*types.Transaction, error) {
- return _Collect.contract.Transact(opts, "withdraw", amount)
- }
- // Withdraw is a paid mutator transaction binding the contract method 0x2e1a7d4d.
- //
- // Solidity: function withdraw(uint256 amount) returns()
- func (_Collect *CollectSession) Withdraw(amount *big.Int) (*types.Transaction, error) {
- return _Collect.Contract.Withdraw(&_Collect.TransactOpts, amount)
- }
- // Withdraw is a paid mutator transaction binding the contract method 0x2e1a7d4d.
- //
- // Solidity: function withdraw(uint256 amount) returns()
- func (_Collect *CollectTransactorSession) Withdraw(amount *big.Int) (*types.Transaction, error) {
- return _Collect.Contract.Withdraw(&_Collect.TransactOpts, amount)
- }
- // CollectClaimIterator is returned from FilterClaim and is used to iterate over the raw logs and unpacked data for Claim events raised by the Collect contract.
- type CollectClaimIterator struct {
- Event *CollectClaim // Event containing the contract specifics and raw log
- contract *bind.BoundContract // Generic contract to use for unpacking event data
- event string // Event name to use for unpacking event data
- logs chan types.Log // Log channel receiving the found contract events
- sub ethereum.Subscription // Subscription for errors, completion and termination
- done bool // Whether the subscription completed delivering logs
- fail error // Occurred error to stop iteration
- }
- // Next advances the iterator to the subsequent event, returning whether there
- // are any more events found. In case of a retrieval or parsing error, false is
- // returned and Error() can be queried for the exact failure.
- func (it *CollectClaimIterator) Next() bool {
- // If the iterator failed, stop iterating
- if it.fail != nil {
- return false
- }
- // If the iterator completed, deliver directly whatever's available
- if it.done {
- select {
- case log := <-it.logs:
- it.Event = new(CollectClaim)
- if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
- it.fail = err
- return false
- }
- it.Event.Raw = log
- return true
- default:
- return false
- }
- }
- // Iterator still in progress, wait for either a data or an error event
- select {
- case log := <-it.logs:
- it.Event = new(CollectClaim)
- if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
- it.fail = err
- return false
- }
- it.Event.Raw = log
- return true
- case err := <-it.sub.Err():
- it.done = true
- it.fail = err
- return it.Next()
- }
- }
- // Error returns any retrieval or parsing error occurred during filtering.
- func (it *CollectClaimIterator) Error() error {
- return it.fail
- }
- // Close terminates the iteration process, releasing any pending underlying
- // resources.
- func (it *CollectClaimIterator) Close() error {
- it.sub.Unsubscribe()
- return nil
- }
- // CollectClaim represents a Claim event raised by the Collect contract.
- type CollectClaim struct {
- User common.Address
- Amount *big.Int
- Signature [32]byte
- Raw types.Log // Blockchain specific contextual infos
- }
- // FilterClaim is a free log retrieval operation binding the contract event 0x4804104ccbc53649f5b8b29ecf858272a4a6ed6b9949f0d30237c7a147e84671.
- //
- // Solidity: event Claim(address user, uint256 amount, bytes32 signature)
- func (_Collect *CollectFilterer) FilterClaim(opts *bind.FilterOpts) (*CollectClaimIterator, error) {
- logs, sub, err := _Collect.contract.FilterLogs(opts, "Claim")
- if err != nil {
- return nil, err
- }
- return &CollectClaimIterator{contract: _Collect.contract, event: "Claim", logs: logs, sub: sub}, nil
- }
- // WatchClaim is a free log subscription operation binding the contract event 0x4804104ccbc53649f5b8b29ecf858272a4a6ed6b9949f0d30237c7a147e84671.
- //
- // Solidity: event Claim(address user, uint256 amount, bytes32 signature)
- func (_Collect *CollectFilterer) WatchClaim(opts *bind.WatchOpts, sink chan<- *CollectClaim) (event.Subscription, error) {
- logs, sub, err := _Collect.contract.WatchLogs(opts, "Claim")
- if err != nil {
- return nil, err
- }
- return event.NewSubscription(func(quit <-chan struct{}) error {
- defer sub.Unsubscribe()
- for {
- select {
- case log := <-logs:
- // New log arrived, parse the event and forward to the user
- event := new(CollectClaim)
- if err := _Collect.contract.UnpackLog(event, "Claim", log); err != nil {
- return err
- }
- event.Raw = log
- select {
- case sink <- event:
- case err := <-sub.Err():
- return err
- case <-quit:
- return nil
- }
- case err := <-sub.Err():
- return err
- case <-quit:
- return nil
- }
- }
- }), nil
- }
- // ParseClaim is a log parse operation binding the contract event 0x4804104ccbc53649f5b8b29ecf858272a4a6ed6b9949f0d30237c7a147e84671.
- //
- // Solidity: event Claim(address user, uint256 amount, bytes32 signature)
- func (_Collect *CollectFilterer) ParseClaim(log types.Log) (*CollectClaim, error) {
- event := new(CollectClaim)
- if err := _Collect.contract.UnpackLog(event, "Claim", log); err != nil {
- return nil, err
- }
- event.Raw = log
- return event, nil
- }
- // CollectOwnershipTransferredIterator is returned from FilterOwnershipTransferred and is used to iterate over the raw logs and unpacked data for OwnershipTransferred events raised by the Collect contract.
- type CollectOwnershipTransferredIterator struct {
- Event *CollectOwnershipTransferred // Event containing the contract specifics and raw log
- contract *bind.BoundContract // Generic contract to use for unpacking event data
- event string // Event name to use for unpacking event data
- logs chan types.Log // Log channel receiving the found contract events
- sub ethereum.Subscription // Subscription for errors, completion and termination
- done bool // Whether the subscription completed delivering logs
- fail error // Occurred error to stop iteration
- }
- // Next advances the iterator to the subsequent event, returning whether there
- // are any more events found. In case of a retrieval or parsing error, false is
- // returned and Error() can be queried for the exact failure.
- func (it *CollectOwnershipTransferredIterator) Next() bool {
- // If the iterator failed, stop iterating
- if it.fail != nil {
- return false
- }
- // If the iterator completed, deliver directly whatever's available
- if it.done {
- select {
- case log := <-it.logs:
- it.Event = new(CollectOwnershipTransferred)
- if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
- it.fail = err
- return false
- }
- it.Event.Raw = log
- return true
- default:
- return false
- }
- }
- // Iterator still in progress, wait for either a data or an error event
- select {
- case log := <-it.logs:
- it.Event = new(CollectOwnershipTransferred)
- if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
- it.fail = err
- return false
- }
- it.Event.Raw = log
- return true
- case err := <-it.sub.Err():
- it.done = true
- it.fail = err
- return it.Next()
- }
- }
- // Error returns any retrieval or parsing error occurred during filtering.
- func (it *CollectOwnershipTransferredIterator) Error() error {
- return it.fail
- }
- // Close terminates the iteration process, releasing any pending underlying
- // resources.
- func (it *CollectOwnershipTransferredIterator) Close() error {
- it.sub.Unsubscribe()
- return nil
- }
- // CollectOwnershipTransferred represents a OwnershipTransferred event raised by the Collect contract.
- type CollectOwnershipTransferred struct {
- PreviousOwner common.Address
- NewOwner common.Address
- Raw types.Log // Blockchain specific contextual infos
- }
- // FilterOwnershipTransferred is a free log retrieval operation binding the contract event 0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0.
- //
- // Solidity: event OwnershipTransferred(address indexed previousOwner, address indexed newOwner)
- func (_Collect *CollectFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, previousOwner []common.Address, newOwner []common.Address) (*CollectOwnershipTransferredIterator, error) {
- var previousOwnerRule []interface{}
- for _, previousOwnerItem := range previousOwner {
- previousOwnerRule = append(previousOwnerRule, previousOwnerItem)
- }
- var newOwnerRule []interface{}
- for _, newOwnerItem := range newOwner {
- newOwnerRule = append(newOwnerRule, newOwnerItem)
- }
- logs, sub, err := _Collect.contract.FilterLogs(opts, "OwnershipTransferred", previousOwnerRule, newOwnerRule)
- if err != nil {
- return nil, err
- }
- return &CollectOwnershipTransferredIterator{contract: _Collect.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil
- }
- // WatchOwnershipTransferred is a free log subscription operation binding the contract event 0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0.
- //
- // Solidity: event OwnershipTransferred(address indexed previousOwner, address indexed newOwner)
- func (_Collect *CollectFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *CollectOwnershipTransferred, previousOwner []common.Address, newOwner []common.Address) (event.Subscription, error) {
- var previousOwnerRule []interface{}
- for _, previousOwnerItem := range previousOwner {
- previousOwnerRule = append(previousOwnerRule, previousOwnerItem)
- }
- var newOwnerRule []interface{}
- for _, newOwnerItem := range newOwner {
- newOwnerRule = append(newOwnerRule, newOwnerItem)
- }
- logs, sub, err := _Collect.contract.WatchLogs(opts, "OwnershipTransferred", previousOwnerRule, newOwnerRule)
- if err != nil {
- return nil, err
- }
- return event.NewSubscription(func(quit <-chan struct{}) error {
- defer sub.Unsubscribe()
- for {
- select {
- case log := <-logs:
- // New log arrived, parse the event and forward to the user
- event := new(CollectOwnershipTransferred)
- if err := _Collect.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil {
- return err
- }
- event.Raw = log
- select {
- case sink <- event:
- case err := <-sub.Err():
- return err
- case <-quit:
- return nil
- }
- case err := <-sub.Err():
- return err
- case <-quit:
- return nil
- }
- }
- }), nil
- }
- // ParseOwnershipTransferred is a log parse operation binding the contract event 0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0.
- //
- // Solidity: event OwnershipTransferred(address indexed previousOwner, address indexed newOwner)
- func (_Collect *CollectFilterer) ParseOwnershipTransferred(log types.Log) (*CollectOwnershipTransferred, error) {
- event := new(CollectOwnershipTransferred)
- if err := _Collect.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil {
- return nil, err
- }
- event.Raw = log
- return event, nil
- }
- // CollectParticipateIterator is returned from FilterParticipate and is used to iterate over the raw logs and unpacked data for Participate events raised by the Collect contract.
- type CollectParticipateIterator struct {
- Event *CollectParticipate // Event containing the contract specifics and raw log
- contract *bind.BoundContract // Generic contract to use for unpacking event data
- event string // Event name to use for unpacking event data
- logs chan types.Log // Log channel receiving the found contract events
- sub ethereum.Subscription // Subscription for errors, completion and termination
- done bool // Whether the subscription completed delivering logs
- fail error // Occurred error to stop iteration
- }
- // Next advances the iterator to the subsequent event, returning whether there
- // are any more events found. In case of a retrieval or parsing error, false is
- // returned and Error() can be queried for the exact failure.
- func (it *CollectParticipateIterator) Next() bool {
- // If the iterator failed, stop iterating
- if it.fail != nil {
- return false
- }
- // If the iterator completed, deliver directly whatever's available
- if it.done {
- select {
- case log := <-it.logs:
- it.Event = new(CollectParticipate)
- if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
- it.fail = err
- return false
- }
- it.Event.Raw = log
- return true
- default:
- return false
- }
- }
- // Iterator still in progress, wait for either a data or an error event
- select {
- case log := <-it.logs:
- it.Event = new(CollectParticipate)
- if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
- it.fail = err
- return false
- }
- it.Event.Raw = log
- return true
- case err := <-it.sub.Err():
- it.done = true
- it.fail = err
- return it.Next()
- }
- }
- // Error returns any retrieval or parsing error occurred during filtering.
- func (it *CollectParticipateIterator) Error() error {
- return it.fail
- }
- // Close terminates the iteration process, releasing any pending underlying
- // resources.
- func (it *CollectParticipateIterator) Close() error {
- it.sub.Unsubscribe()
- return nil
- }
- // CollectParticipate represents a Participate event raised by the Collect contract.
- type CollectParticipate struct {
- Participant common.Address
- Inviter common.Address
- Amount *big.Int
- Raw types.Log // Blockchain specific contextual infos
- }
- // FilterParticipate is a free log retrieval operation binding the contract event 0x8ed860f76da405897619eab937f09dcb4d0d9b56cf68a3d489130a2489cf151f.
- //
- // Solidity: event Participate(address participant, address inviter, uint256 amount)
- func (_Collect *CollectFilterer) FilterParticipate(opts *bind.FilterOpts) (*CollectParticipateIterator, error) {
- logs, sub, err := _Collect.contract.FilterLogs(opts, "Participate")
- if err != nil {
- return nil, err
- }
- return &CollectParticipateIterator{contract: _Collect.contract, event: "Participate", logs: logs, sub: sub}, nil
- }
- // WatchParticipate is a free log subscription operation binding the contract event 0x8ed860f76da405897619eab937f09dcb4d0d9b56cf68a3d489130a2489cf151f.
- //
- // Solidity: event Participate(address participant, address inviter, uint256 amount)
- func (_Collect *CollectFilterer) WatchParticipate(opts *bind.WatchOpts, sink chan<- *CollectParticipate) (event.Subscription, error) {
- logs, sub, err := _Collect.contract.WatchLogs(opts, "Participate")
- if err != nil {
- return nil, err
- }
- return event.NewSubscription(func(quit <-chan struct{}) error {
- defer sub.Unsubscribe()
- for {
- select {
- case log := <-logs:
- // New log arrived, parse the event and forward to the user
- event := new(CollectParticipate)
- if err := _Collect.contract.UnpackLog(event, "Participate", log); err != nil {
- return err
- }
- event.Raw = log
- select {
- case sink <- event:
- case err := <-sub.Err():
- return err
- case <-quit:
- return nil
- }
- case err := <-sub.Err():
- return err
- case <-quit:
- return nil
- }
- }
- }), nil
- }
- // ParseParticipate is a log parse operation binding the contract event 0x8ed860f76da405897619eab937f09dcb4d0d9b56cf68a3d489130a2489cf151f.
- //
- // Solidity: event Participate(address participant, address inviter, uint256 amount)
- func (_Collect *CollectFilterer) ParseParticipate(log types.Log) (*CollectParticipate, error) {
- event := new(CollectParticipate)
- if err := _Collect.contract.UnpackLog(event, "Participate", log); err != nil {
- return nil, err
- }
- event.Raw = log
- return event, nil
- }
- // CollectRemoveManagerIterator is returned from FilterRemoveManager and is used to iterate over the raw logs and unpacked data for RemoveManager events raised by the Collect contract.
- type CollectRemoveManagerIterator struct {
- Event *CollectRemoveManager // Event containing the contract specifics and raw log
- contract *bind.BoundContract // Generic contract to use for unpacking event data
- event string // Event name to use for unpacking event data
- logs chan types.Log // Log channel receiving the found contract events
- sub ethereum.Subscription // Subscription for errors, completion and termination
- done bool // Whether the subscription completed delivering logs
- fail error // Occurred error to stop iteration
- }
- // Next advances the iterator to the subsequent event, returning whether there
- // are any more events found. In case of a retrieval or parsing error, false is
- // returned and Error() can be queried for the exact failure.
- func (it *CollectRemoveManagerIterator) Next() bool {
- // If the iterator failed, stop iterating
- if it.fail != nil {
- return false
- }
- // If the iterator completed, deliver directly whatever's available
- if it.done {
- select {
- case log := <-it.logs:
- it.Event = new(CollectRemoveManager)
- if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
- it.fail = err
- return false
- }
- it.Event.Raw = log
- return true
- default:
- return false
- }
- }
- // Iterator still in progress, wait for either a data or an error event
- select {
- case log := <-it.logs:
- it.Event = new(CollectRemoveManager)
- if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
- it.fail = err
- return false
- }
- it.Event.Raw = log
- return true
- case err := <-it.sub.Err():
- it.done = true
- it.fail = err
- return it.Next()
- }
- }
- // Error returns any retrieval or parsing error occurred during filtering.
- func (it *CollectRemoveManagerIterator) Error() error {
- return it.fail
- }
- // Close terminates the iteration process, releasing any pending underlying
- // resources.
- func (it *CollectRemoveManagerIterator) Close() error {
- it.sub.Unsubscribe()
- return nil
- }
- // CollectRemoveManager represents a RemoveManager event raised by the Collect contract.
- type CollectRemoveManager struct {
- Manager common.Address
- Raw types.Log // Blockchain specific contextual infos
- }
- // FilterRemoveManager is a free log retrieval operation binding the contract event 0x1e25ed4cabec84d314dc176241019653f237da01f2bdd3a10cb0f38b33da6763.
- //
- // Solidity: event RemoveManager(address _manager)
- func (_Collect *CollectFilterer) FilterRemoveManager(opts *bind.FilterOpts) (*CollectRemoveManagerIterator, error) {
- logs, sub, err := _Collect.contract.FilterLogs(opts, "RemoveManager")
- if err != nil {
- return nil, err
- }
- return &CollectRemoveManagerIterator{contract: _Collect.contract, event: "RemoveManager", logs: logs, sub: sub}, nil
- }
- // WatchRemoveManager is a free log subscription operation binding the contract event 0x1e25ed4cabec84d314dc176241019653f237da01f2bdd3a10cb0f38b33da6763.
- //
- // Solidity: event RemoveManager(address _manager)
- func (_Collect *CollectFilterer) WatchRemoveManager(opts *bind.WatchOpts, sink chan<- *CollectRemoveManager) (event.Subscription, error) {
- logs, sub, err := _Collect.contract.WatchLogs(opts, "RemoveManager")
- if err != nil {
- return nil, err
- }
- return event.NewSubscription(func(quit <-chan struct{}) error {
- defer sub.Unsubscribe()
- for {
- select {
- case log := <-logs:
- // New log arrived, parse the event and forward to the user
- event := new(CollectRemoveManager)
- if err := _Collect.contract.UnpackLog(event, "RemoveManager", log); err != nil {
- return err
- }
- event.Raw = log
- select {
- case sink <- event:
- case err := <-sub.Err():
- return err
- case <-quit:
- return nil
- }
- case err := <-sub.Err():
- return err
- case <-quit:
- return nil
- }
- }
- }), nil
- }
- // ParseRemoveManager is a log parse operation binding the contract event 0x1e25ed4cabec84d314dc176241019653f237da01f2bdd3a10cb0f38b33da6763.
- //
- // Solidity: event RemoveManager(address _manager)
- func (_Collect *CollectFilterer) ParseRemoveManager(log types.Log) (*CollectRemoveManager, error) {
- event := new(CollectRemoveManager)
- if err := _Collect.contract.UnpackLog(event, "RemoveManager", log); err != nil {
- return nil, err
- }
- event.Raw = log
- return event, nil
- }
- // CollectSetManagerIterator is returned from FilterSetManager and is used to iterate over the raw logs and unpacked data for SetManager events raised by the Collect contract.
- type CollectSetManagerIterator struct {
- Event *CollectSetManager // Event containing the contract specifics and raw log
- contract *bind.BoundContract // Generic contract to use for unpacking event data
- event string // Event name to use for unpacking event data
- logs chan types.Log // Log channel receiving the found contract events
- sub ethereum.Subscription // Subscription for errors, completion and termination
- done bool // Whether the subscription completed delivering logs
- fail error // Occurred error to stop iteration
- }
- // Next advances the iterator to the subsequent event, returning whether there
- // are any more events found. In case of a retrieval or parsing error, false is
- // returned and Error() can be queried for the exact failure.
- func (it *CollectSetManagerIterator) Next() bool {
- // If the iterator failed, stop iterating
- if it.fail != nil {
- return false
- }
- // If the iterator completed, deliver directly whatever's available
- if it.done {
- select {
- case log := <-it.logs:
- it.Event = new(CollectSetManager)
- if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
- it.fail = err
- return false
- }
- it.Event.Raw = log
- return true
- default:
- return false
- }
- }
- // Iterator still in progress, wait for either a data or an error event
- select {
- case log := <-it.logs:
- it.Event = new(CollectSetManager)
- if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
- it.fail = err
- return false
- }
- it.Event.Raw = log
- return true
- case err := <-it.sub.Err():
- it.done = true
- it.fail = err
- return it.Next()
- }
- }
- // Error returns any retrieval or parsing error occurred during filtering.
- func (it *CollectSetManagerIterator) Error() error {
- return it.fail
- }
- // Close terminates the iteration process, releasing any pending underlying
- // resources.
- func (it *CollectSetManagerIterator) Close() error {
- it.sub.Unsubscribe()
- return nil
- }
- // CollectSetManager represents a SetManager event raised by the Collect contract.
- type CollectSetManager struct {
- Manager common.Address
- Raw types.Log // Blockchain specific contextual infos
- }
- // FilterSetManager is a free log retrieval operation binding the contract event 0x54a6385aa0292b04e1ef8513253c17d1863f7cdfc87029d77fd55cc4c2e717e2.
- //
- // Solidity: event SetManager(address _manager)
- func (_Collect *CollectFilterer) FilterSetManager(opts *bind.FilterOpts) (*CollectSetManagerIterator, error) {
- logs, sub, err := _Collect.contract.FilterLogs(opts, "SetManager")
- if err != nil {
- return nil, err
- }
- return &CollectSetManagerIterator{contract: _Collect.contract, event: "SetManager", logs: logs, sub: sub}, nil
- }
- // WatchSetManager is a free log subscription operation binding the contract event 0x54a6385aa0292b04e1ef8513253c17d1863f7cdfc87029d77fd55cc4c2e717e2.
- //
- // Solidity: event SetManager(address _manager)
- func (_Collect *CollectFilterer) WatchSetManager(opts *bind.WatchOpts, sink chan<- *CollectSetManager) (event.Subscription, error) {
- logs, sub, err := _Collect.contract.WatchLogs(opts, "SetManager")
- if err != nil {
- return nil, err
- }
- return event.NewSubscription(func(quit <-chan struct{}) error {
- defer sub.Unsubscribe()
- for {
- select {
- case log := <-logs:
- // New log arrived, parse the event and forward to the user
- event := new(CollectSetManager)
- if err := _Collect.contract.UnpackLog(event, "SetManager", log); err != nil {
- return err
- }
- event.Raw = log
- select {
- case sink <- event:
- case err := <-sub.Err():
- return err
- case <-quit:
- return nil
- }
- case err := <-sub.Err():
- return err
- case <-quit:
- return nil
- }
- }
- }), nil
- }
- // ParseSetManager is a log parse operation binding the contract event 0x54a6385aa0292b04e1ef8513253c17d1863f7cdfc87029d77fd55cc4c2e717e2.
- //
- // Solidity: event SetManager(address _manager)
- func (_Collect *CollectFilterer) ParseSetManager(log types.Log) (*CollectSetManager, error) {
- event := new(CollectSetManager)
- if err := _Collect.contract.UnpackLog(event, "SetManager", log); err != nil {
- return nil, err
- }
- event.Raw = log
- return event, nil
- }
|