// Code generated - DO NOT EDIT. // This file is a generated binding and any manual changes will be lost. package l2gateway 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 _ = abi.ConvertType ) // AddressUpgradeableMetaData contains all meta data concerning the AddressUpgradeable contract. var AddressUpgradeableMetaData = &bind.MetaData{ ABI: "[]", Bin: "0x60566037600b82828239805160001a607314602a57634e487b7160e01b600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212205356b5e9321caaaa94b31cd006b1fc2ab50006bb05ef5ed777873484aed2aba064736f6c63430008110033", } // AddressUpgradeableABI is the input ABI used to generate the binding from. // Deprecated: Use AddressUpgradeableMetaData.ABI instead. var AddressUpgradeableABI = AddressUpgradeableMetaData.ABI // AddressUpgradeableBin is the compiled bytecode used for deploying new contracts. // Deprecated: Use AddressUpgradeableMetaData.Bin instead. var AddressUpgradeableBin = AddressUpgradeableMetaData.Bin // DeployAddressUpgradeable deploys a new Ethereum contract, binding an instance of AddressUpgradeable to it. func DeployAddressUpgradeable(auth *bind.TransactOpts, backend bind.ContractBackend) (common.Address, *types.Transaction, *AddressUpgradeable, error) { parsed, err := AddressUpgradeableMetaData.GetAbi() if err != nil { return common.Address{}, nil, nil, err } if parsed == nil { return common.Address{}, nil, nil, errors.New("GetABI returned nil") } address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(AddressUpgradeableBin), backend) if err != nil { return common.Address{}, nil, nil, err } return address, tx, &AddressUpgradeable{AddressUpgradeableCaller: AddressUpgradeableCaller{contract: contract}, AddressUpgradeableTransactor: AddressUpgradeableTransactor{contract: contract}, AddressUpgradeableFilterer: AddressUpgradeableFilterer{contract: contract}}, nil } // AddressUpgradeable is an auto generated Go binding around an Ethereum contract. type AddressUpgradeable struct { AddressUpgradeableCaller // Read-only binding to the contract AddressUpgradeableTransactor // Write-only binding to the contract AddressUpgradeableFilterer // Log filterer for contract events } // AddressUpgradeableCaller is an auto generated read-only Go binding around an Ethereum contract. type AddressUpgradeableCaller struct { contract *bind.BoundContract // Generic contract wrapper for the low level calls } // AddressUpgradeableTransactor is an auto generated write-only Go binding around an Ethereum contract. type AddressUpgradeableTransactor struct { contract *bind.BoundContract // Generic contract wrapper for the low level calls } // AddressUpgradeableFilterer is an auto generated log filtering Go binding around an Ethereum contract events. type AddressUpgradeableFilterer struct { contract *bind.BoundContract // Generic contract wrapper for the low level calls } // AddressUpgradeableSession is an auto generated Go binding around an Ethereum contract, // with pre-set call and transact options. type AddressUpgradeableSession struct { Contract *AddressUpgradeable // 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 } // AddressUpgradeableCallerSession is an auto generated read-only Go binding around an Ethereum contract, // with pre-set call options. type AddressUpgradeableCallerSession struct { Contract *AddressUpgradeableCaller // Generic contract caller binding to set the session for CallOpts bind.CallOpts // Call options to use throughout this session } // AddressUpgradeableTransactorSession is an auto generated write-only Go binding around an Ethereum contract, // with pre-set transact options. type AddressUpgradeableTransactorSession struct { Contract *AddressUpgradeableTransactor // Generic contract transactor binding to set the session for TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session } // AddressUpgradeableRaw is an auto generated low-level Go binding around an Ethereum contract. type AddressUpgradeableRaw struct { Contract *AddressUpgradeable // Generic contract binding to access the raw methods on } // AddressUpgradeableCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract. type AddressUpgradeableCallerRaw struct { Contract *AddressUpgradeableCaller // Generic read-only contract binding to access the raw methods on } // AddressUpgradeableTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract. type AddressUpgradeableTransactorRaw struct { Contract *AddressUpgradeableTransactor // Generic write-only contract binding to access the raw methods on } // NewAddressUpgradeable creates a new instance of AddressUpgradeable, bound to a specific deployed contract. func NewAddressUpgradeable(address common.Address, backend bind.ContractBackend) (*AddressUpgradeable, error) { contract, err := bindAddressUpgradeable(address, backend, backend, backend) if err != nil { return nil, err } return &AddressUpgradeable{AddressUpgradeableCaller: AddressUpgradeableCaller{contract: contract}, AddressUpgradeableTransactor: AddressUpgradeableTransactor{contract: contract}, AddressUpgradeableFilterer: AddressUpgradeableFilterer{contract: contract}}, nil } // NewAddressUpgradeableCaller creates a new read-only instance of AddressUpgradeable, bound to a specific deployed contract. func NewAddressUpgradeableCaller(address common.Address, caller bind.ContractCaller) (*AddressUpgradeableCaller, error) { contract, err := bindAddressUpgradeable(address, caller, nil, nil) if err != nil { return nil, err } return &AddressUpgradeableCaller{contract: contract}, nil } // NewAddressUpgradeableTransactor creates a new write-only instance of AddressUpgradeable, bound to a specific deployed contract. func NewAddressUpgradeableTransactor(address common.Address, transactor bind.ContractTransactor) (*AddressUpgradeableTransactor, error) { contract, err := bindAddressUpgradeable(address, nil, transactor, nil) if err != nil { return nil, err } return &AddressUpgradeableTransactor{contract: contract}, nil } // NewAddressUpgradeableFilterer creates a new log filterer instance of AddressUpgradeable, bound to a specific deployed contract. func NewAddressUpgradeableFilterer(address common.Address, filterer bind.ContractFilterer) (*AddressUpgradeableFilterer, error) { contract, err := bindAddressUpgradeable(address, nil, nil, filterer) if err != nil { return nil, err } return &AddressUpgradeableFilterer{contract: contract}, nil } // bindAddressUpgradeable binds a generic wrapper to an already deployed contract. func bindAddressUpgradeable(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { parsed, err := AddressUpgradeableMetaData.GetAbi() 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 (_AddressUpgradeable *AddressUpgradeableRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { return _AddressUpgradeable.Contract.AddressUpgradeableCaller.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 (_AddressUpgradeable *AddressUpgradeableRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { return _AddressUpgradeable.Contract.AddressUpgradeableTransactor.contract.Transfer(opts) } // Transact invokes the (paid) contract method with params as input values. func (_AddressUpgradeable *AddressUpgradeableRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { return _AddressUpgradeable.Contract.AddressUpgradeableTransactor.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 (_AddressUpgradeable *AddressUpgradeableCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { return _AddressUpgradeable.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 (_AddressUpgradeable *AddressUpgradeableTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { return _AddressUpgradeable.Contract.contract.Transfer(opts) } // Transact invokes the (paid) contract method with params as input values. func (_AddressUpgradeable *AddressUpgradeableTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { return _AddressUpgradeable.Contract.contract.Transact(opts, method, params...) } // ContextUpgradeableMetaData contains all meta data concerning the ContextUpgradeable contract. var ContextUpgradeableMetaData = &bind.MetaData{ ABI: "[{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"name\":\"Initialized\",\"type\":\"event\"}]", } // ContextUpgradeableABI is the input ABI used to generate the binding from. // Deprecated: Use ContextUpgradeableMetaData.ABI instead. var ContextUpgradeableABI = ContextUpgradeableMetaData.ABI // ContextUpgradeable is an auto generated Go binding around an Ethereum contract. type ContextUpgradeable struct { ContextUpgradeableCaller // Read-only binding to the contract ContextUpgradeableTransactor // Write-only binding to the contract ContextUpgradeableFilterer // Log filterer for contract events } // ContextUpgradeableCaller is an auto generated read-only Go binding around an Ethereum contract. type ContextUpgradeableCaller struct { contract *bind.BoundContract // Generic contract wrapper for the low level calls } // ContextUpgradeableTransactor is an auto generated write-only Go binding around an Ethereum contract. type ContextUpgradeableTransactor struct { contract *bind.BoundContract // Generic contract wrapper for the low level calls } // ContextUpgradeableFilterer is an auto generated log filtering Go binding around an Ethereum contract events. type ContextUpgradeableFilterer struct { contract *bind.BoundContract // Generic contract wrapper for the low level calls } // ContextUpgradeableSession is an auto generated Go binding around an Ethereum contract, // with pre-set call and transact options. type ContextUpgradeableSession struct { Contract *ContextUpgradeable // 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 } // ContextUpgradeableCallerSession is an auto generated read-only Go binding around an Ethereum contract, // with pre-set call options. type ContextUpgradeableCallerSession struct { Contract *ContextUpgradeableCaller // Generic contract caller binding to set the session for CallOpts bind.CallOpts // Call options to use throughout this session } // ContextUpgradeableTransactorSession is an auto generated write-only Go binding around an Ethereum contract, // with pre-set transact options. type ContextUpgradeableTransactorSession struct { Contract *ContextUpgradeableTransactor // Generic contract transactor binding to set the session for TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session } // ContextUpgradeableRaw is an auto generated low-level Go binding around an Ethereum contract. type ContextUpgradeableRaw struct { Contract *ContextUpgradeable // Generic contract binding to access the raw methods on } // ContextUpgradeableCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract. type ContextUpgradeableCallerRaw struct { Contract *ContextUpgradeableCaller // Generic read-only contract binding to access the raw methods on } // ContextUpgradeableTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract. type ContextUpgradeableTransactorRaw struct { Contract *ContextUpgradeableTransactor // Generic write-only contract binding to access the raw methods on } // NewContextUpgradeable creates a new instance of ContextUpgradeable, bound to a specific deployed contract. func NewContextUpgradeable(address common.Address, backend bind.ContractBackend) (*ContextUpgradeable, error) { contract, err := bindContextUpgradeable(address, backend, backend, backend) if err != nil { return nil, err } return &ContextUpgradeable{ContextUpgradeableCaller: ContextUpgradeableCaller{contract: contract}, ContextUpgradeableTransactor: ContextUpgradeableTransactor{contract: contract}, ContextUpgradeableFilterer: ContextUpgradeableFilterer{contract: contract}}, nil } // NewContextUpgradeableCaller creates a new read-only instance of ContextUpgradeable, bound to a specific deployed contract. func NewContextUpgradeableCaller(address common.Address, caller bind.ContractCaller) (*ContextUpgradeableCaller, error) { contract, err := bindContextUpgradeable(address, caller, nil, nil) if err != nil { return nil, err } return &ContextUpgradeableCaller{contract: contract}, nil } // NewContextUpgradeableTransactor creates a new write-only instance of ContextUpgradeable, bound to a specific deployed contract. func NewContextUpgradeableTransactor(address common.Address, transactor bind.ContractTransactor) (*ContextUpgradeableTransactor, error) { contract, err := bindContextUpgradeable(address, nil, transactor, nil) if err != nil { return nil, err } return &ContextUpgradeableTransactor{contract: contract}, nil } // NewContextUpgradeableFilterer creates a new log filterer instance of ContextUpgradeable, bound to a specific deployed contract. func NewContextUpgradeableFilterer(address common.Address, filterer bind.ContractFilterer) (*ContextUpgradeableFilterer, error) { contract, err := bindContextUpgradeable(address, nil, nil, filterer) if err != nil { return nil, err } return &ContextUpgradeableFilterer{contract: contract}, nil } // bindContextUpgradeable binds a generic wrapper to an already deployed contract. func bindContextUpgradeable(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { parsed, err := ContextUpgradeableMetaData.GetAbi() 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 (_ContextUpgradeable *ContextUpgradeableRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { return _ContextUpgradeable.Contract.ContextUpgradeableCaller.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 (_ContextUpgradeable *ContextUpgradeableRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { return _ContextUpgradeable.Contract.ContextUpgradeableTransactor.contract.Transfer(opts) } // Transact invokes the (paid) contract method with params as input values. func (_ContextUpgradeable *ContextUpgradeableRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { return _ContextUpgradeable.Contract.ContextUpgradeableTransactor.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 (_ContextUpgradeable *ContextUpgradeableCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { return _ContextUpgradeable.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 (_ContextUpgradeable *ContextUpgradeableTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { return _ContextUpgradeable.Contract.contract.Transfer(opts) } // Transact invokes the (paid) contract method with params as input values. func (_ContextUpgradeable *ContextUpgradeableTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { return _ContextUpgradeable.Contract.contract.Transact(opts, method, params...) } // ContextUpgradeableInitializedIterator is returned from FilterInitialized and is used to iterate over the raw logs and unpacked data for Initialized events raised by the ContextUpgradeable contract. type ContextUpgradeableInitializedIterator struct { Event *ContextUpgradeableInitialized // 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 *ContextUpgradeableInitializedIterator) 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(ContextUpgradeableInitialized) 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(ContextUpgradeableInitialized) 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 *ContextUpgradeableInitializedIterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. func (it *ContextUpgradeableInitializedIterator) Close() error { it.sub.Unsubscribe() return nil } // ContextUpgradeableInitialized represents a Initialized event raised by the ContextUpgradeable contract. type ContextUpgradeableInitialized struct { Version uint8 Raw types.Log // Blockchain specific contextual infos } // FilterInitialized is a free log retrieval operation binding the contract event 0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498. // // Solidity: event Initialized(uint8 version) func (_ContextUpgradeable *ContextUpgradeableFilterer) FilterInitialized(opts *bind.FilterOpts) (*ContextUpgradeableInitializedIterator, error) { logs, sub, err := _ContextUpgradeable.contract.FilterLogs(opts, "Initialized") if err != nil { return nil, err } return &ContextUpgradeableInitializedIterator{contract: _ContextUpgradeable.contract, event: "Initialized", logs: logs, sub: sub}, nil } // WatchInitialized is a free log subscription operation binding the contract event 0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498. // // Solidity: event Initialized(uint8 version) func (_ContextUpgradeable *ContextUpgradeableFilterer) WatchInitialized(opts *bind.WatchOpts, sink chan<- *ContextUpgradeableInitialized) (event.Subscription, error) { logs, sub, err := _ContextUpgradeable.contract.WatchLogs(opts, "Initialized") 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(ContextUpgradeableInitialized) if err := _ContextUpgradeable.contract.UnpackLog(event, "Initialized", 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 } // ParseInitialized is a log parse operation binding the contract event 0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498. // // Solidity: event Initialized(uint8 version) func (_ContextUpgradeable *ContextUpgradeableFilterer) ParseInitialized(log types.Log) (*ContextUpgradeableInitialized, error) { event := new(ContextUpgradeableInitialized) if err := _ContextUpgradeable.contract.UnpackLog(event, "Initialized", log); err != nil { return nil, err } event.Raw = log return event, nil } // IL2ERC20GatewayMetaData contains all meta data concerning the IL2ERC20Gateway contract. var IL2ERC20GatewayMetaData = &bind.MetaData{ ABI: "[{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"l1Token\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"l2Token\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"FinalizeDepositERC20\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"l1Token\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"l2Token\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"WithdrawERC20\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"l1Token\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"l2Token\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"finalizeDepositERC20\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"l2Token\",\"type\":\"address\"}],\"name\":\"getL1ERC20Address\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"l1Token\",\"type\":\"address\"}],\"name\":\"getL2ERC20Address\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"}],\"name\":\"withdrawERC20\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"}],\"name\":\"withdrawERC20\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"}],\"name\":\"withdrawERC20AndCall\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"}]", Sigs: map[string]string{ "8431f5c1": "finalizeDepositERC20(address,address,address,address,uint256,bytes)", "54bbd59c": "getL1ERC20Address(address)", "c676ad29": "getL2ERC20Address(address)", "a93a4af9": "withdrawERC20(address,address,uint256,uint256)", "6c07ea43": "withdrawERC20(address,uint256,uint256)", "575361b6": "withdrawERC20AndCall(address,address,uint256,bytes,uint256)", }, } // IL2ERC20GatewayABI is the input ABI used to generate the binding from. // Deprecated: Use IL2ERC20GatewayMetaData.ABI instead. var IL2ERC20GatewayABI = IL2ERC20GatewayMetaData.ABI // Deprecated: Use IL2ERC20GatewayMetaData.Sigs instead. // IL2ERC20GatewayFuncSigs maps the 4-byte function signature to its string representation. var IL2ERC20GatewayFuncSigs = IL2ERC20GatewayMetaData.Sigs // IL2ERC20Gateway is an auto generated Go binding around an Ethereum contract. type IL2ERC20Gateway struct { IL2ERC20GatewayCaller // Read-only binding to the contract IL2ERC20GatewayTransactor // Write-only binding to the contract IL2ERC20GatewayFilterer // Log filterer for contract events } // IL2ERC20GatewayCaller is an auto generated read-only Go binding around an Ethereum contract. type IL2ERC20GatewayCaller struct { contract *bind.BoundContract // Generic contract wrapper for the low level calls } // IL2ERC20GatewayTransactor is an auto generated write-only Go binding around an Ethereum contract. type IL2ERC20GatewayTransactor struct { contract *bind.BoundContract // Generic contract wrapper for the low level calls } // IL2ERC20GatewayFilterer is an auto generated log filtering Go binding around an Ethereum contract events. type IL2ERC20GatewayFilterer struct { contract *bind.BoundContract // Generic contract wrapper for the low level calls } // IL2ERC20GatewaySession is an auto generated Go binding around an Ethereum contract, // with pre-set call and transact options. type IL2ERC20GatewaySession struct { Contract *IL2ERC20Gateway // 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 } // IL2ERC20GatewayCallerSession is an auto generated read-only Go binding around an Ethereum contract, // with pre-set call options. type IL2ERC20GatewayCallerSession struct { Contract *IL2ERC20GatewayCaller // Generic contract caller binding to set the session for CallOpts bind.CallOpts // Call options to use throughout this session } // IL2ERC20GatewayTransactorSession is an auto generated write-only Go binding around an Ethereum contract, // with pre-set transact options. type IL2ERC20GatewayTransactorSession struct { Contract *IL2ERC20GatewayTransactor // Generic contract transactor binding to set the session for TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session } // IL2ERC20GatewayRaw is an auto generated low-level Go binding around an Ethereum contract. type IL2ERC20GatewayRaw struct { Contract *IL2ERC20Gateway // Generic contract binding to access the raw methods on } // IL2ERC20GatewayCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract. type IL2ERC20GatewayCallerRaw struct { Contract *IL2ERC20GatewayCaller // Generic read-only contract binding to access the raw methods on } // IL2ERC20GatewayTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract. type IL2ERC20GatewayTransactorRaw struct { Contract *IL2ERC20GatewayTransactor // Generic write-only contract binding to access the raw methods on } // NewIL2ERC20Gateway creates a new instance of IL2ERC20Gateway, bound to a specific deployed contract. func NewIL2ERC20Gateway(address common.Address, backend bind.ContractBackend) (*IL2ERC20Gateway, error) { contract, err := bindIL2ERC20Gateway(address, backend, backend, backend) if err != nil { return nil, err } return &IL2ERC20Gateway{IL2ERC20GatewayCaller: IL2ERC20GatewayCaller{contract: contract}, IL2ERC20GatewayTransactor: IL2ERC20GatewayTransactor{contract: contract}, IL2ERC20GatewayFilterer: IL2ERC20GatewayFilterer{contract: contract}}, nil } // NewIL2ERC20GatewayCaller creates a new read-only instance of IL2ERC20Gateway, bound to a specific deployed contract. func NewIL2ERC20GatewayCaller(address common.Address, caller bind.ContractCaller) (*IL2ERC20GatewayCaller, error) { contract, err := bindIL2ERC20Gateway(address, caller, nil, nil) if err != nil { return nil, err } return &IL2ERC20GatewayCaller{contract: contract}, nil } // NewIL2ERC20GatewayTransactor creates a new write-only instance of IL2ERC20Gateway, bound to a specific deployed contract. func NewIL2ERC20GatewayTransactor(address common.Address, transactor bind.ContractTransactor) (*IL2ERC20GatewayTransactor, error) { contract, err := bindIL2ERC20Gateway(address, nil, transactor, nil) if err != nil { return nil, err } return &IL2ERC20GatewayTransactor{contract: contract}, nil } // NewIL2ERC20GatewayFilterer creates a new log filterer instance of IL2ERC20Gateway, bound to a specific deployed contract. func NewIL2ERC20GatewayFilterer(address common.Address, filterer bind.ContractFilterer) (*IL2ERC20GatewayFilterer, error) { contract, err := bindIL2ERC20Gateway(address, nil, nil, filterer) if err != nil { return nil, err } return &IL2ERC20GatewayFilterer{contract: contract}, nil } // bindIL2ERC20Gateway binds a generic wrapper to an already deployed contract. func bindIL2ERC20Gateway(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { parsed, err := IL2ERC20GatewayMetaData.GetAbi() 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 (_IL2ERC20Gateway *IL2ERC20GatewayRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { return _IL2ERC20Gateway.Contract.IL2ERC20GatewayCaller.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 (_IL2ERC20Gateway *IL2ERC20GatewayRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { return _IL2ERC20Gateway.Contract.IL2ERC20GatewayTransactor.contract.Transfer(opts) } // Transact invokes the (paid) contract method with params as input values. func (_IL2ERC20Gateway *IL2ERC20GatewayRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { return _IL2ERC20Gateway.Contract.IL2ERC20GatewayTransactor.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 (_IL2ERC20Gateway *IL2ERC20GatewayCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { return _IL2ERC20Gateway.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 (_IL2ERC20Gateway *IL2ERC20GatewayTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { return _IL2ERC20Gateway.Contract.contract.Transfer(opts) } // Transact invokes the (paid) contract method with params as input values. func (_IL2ERC20Gateway *IL2ERC20GatewayTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { return _IL2ERC20Gateway.Contract.contract.Transact(opts, method, params...) } // GetL1ERC20Address is a free data retrieval call binding the contract method 0x54bbd59c. // // Solidity: function getL1ERC20Address(address l2Token) view returns(address) func (_IL2ERC20Gateway *IL2ERC20GatewayCaller) GetL1ERC20Address(opts *bind.CallOpts, l2Token common.Address) (common.Address, error) { var out []interface{} err := _IL2ERC20Gateway.contract.Call(opts, &out, "getL1ERC20Address", l2Token) if err != nil { return *new(common.Address), err } out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) return out0, err } // GetL1ERC20Address is a free data retrieval call binding the contract method 0x54bbd59c. // // Solidity: function getL1ERC20Address(address l2Token) view returns(address) func (_IL2ERC20Gateway *IL2ERC20GatewaySession) GetL1ERC20Address(l2Token common.Address) (common.Address, error) { return _IL2ERC20Gateway.Contract.GetL1ERC20Address(&_IL2ERC20Gateway.CallOpts, l2Token) } // GetL1ERC20Address is a free data retrieval call binding the contract method 0x54bbd59c. // // Solidity: function getL1ERC20Address(address l2Token) view returns(address) func (_IL2ERC20Gateway *IL2ERC20GatewayCallerSession) GetL1ERC20Address(l2Token common.Address) (common.Address, error) { return _IL2ERC20Gateway.Contract.GetL1ERC20Address(&_IL2ERC20Gateway.CallOpts, l2Token) } // GetL2ERC20Address is a free data retrieval call binding the contract method 0xc676ad29. // // Solidity: function getL2ERC20Address(address l1Token) view returns(address) func (_IL2ERC20Gateway *IL2ERC20GatewayCaller) GetL2ERC20Address(opts *bind.CallOpts, l1Token common.Address) (common.Address, error) { var out []interface{} err := _IL2ERC20Gateway.contract.Call(opts, &out, "getL2ERC20Address", l1Token) if err != nil { return *new(common.Address), err } out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) return out0, err } // GetL2ERC20Address is a free data retrieval call binding the contract method 0xc676ad29. // // Solidity: function getL2ERC20Address(address l1Token) view returns(address) func (_IL2ERC20Gateway *IL2ERC20GatewaySession) GetL2ERC20Address(l1Token common.Address) (common.Address, error) { return _IL2ERC20Gateway.Contract.GetL2ERC20Address(&_IL2ERC20Gateway.CallOpts, l1Token) } // GetL2ERC20Address is a free data retrieval call binding the contract method 0xc676ad29. // // Solidity: function getL2ERC20Address(address l1Token) view returns(address) func (_IL2ERC20Gateway *IL2ERC20GatewayCallerSession) GetL2ERC20Address(l1Token common.Address) (common.Address, error) { return _IL2ERC20Gateway.Contract.GetL2ERC20Address(&_IL2ERC20Gateway.CallOpts, l1Token) } // FinalizeDepositERC20 is a paid mutator transaction binding the contract method 0x8431f5c1. // // Solidity: function finalizeDepositERC20(address l1Token, address l2Token, address from, address to, uint256 amount, bytes data) payable returns() func (_IL2ERC20Gateway *IL2ERC20GatewayTransactor) FinalizeDepositERC20(opts *bind.TransactOpts, l1Token common.Address, l2Token common.Address, from common.Address, to common.Address, amount *big.Int, data []byte) (*types.Transaction, error) { return _IL2ERC20Gateway.contract.Transact(opts, "finalizeDepositERC20", l1Token, l2Token, from, to, amount, data) } // FinalizeDepositERC20 is a paid mutator transaction binding the contract method 0x8431f5c1. // // Solidity: function finalizeDepositERC20(address l1Token, address l2Token, address from, address to, uint256 amount, bytes data) payable returns() func (_IL2ERC20Gateway *IL2ERC20GatewaySession) FinalizeDepositERC20(l1Token common.Address, l2Token common.Address, from common.Address, to common.Address, amount *big.Int, data []byte) (*types.Transaction, error) { return _IL2ERC20Gateway.Contract.FinalizeDepositERC20(&_IL2ERC20Gateway.TransactOpts, l1Token, l2Token, from, to, amount, data) } // FinalizeDepositERC20 is a paid mutator transaction binding the contract method 0x8431f5c1. // // Solidity: function finalizeDepositERC20(address l1Token, address l2Token, address from, address to, uint256 amount, bytes data) payable returns() func (_IL2ERC20Gateway *IL2ERC20GatewayTransactorSession) FinalizeDepositERC20(l1Token common.Address, l2Token common.Address, from common.Address, to common.Address, amount *big.Int, data []byte) (*types.Transaction, error) { return _IL2ERC20Gateway.Contract.FinalizeDepositERC20(&_IL2ERC20Gateway.TransactOpts, l1Token, l2Token, from, to, amount, data) } // WithdrawERC20 is a paid mutator transaction binding the contract method 0x6c07ea43. // // Solidity: function withdrawERC20(address token, uint256 amount, uint256 gasLimit) payable returns() func (_IL2ERC20Gateway *IL2ERC20GatewayTransactor) WithdrawERC20(opts *bind.TransactOpts, token common.Address, amount *big.Int, gasLimit *big.Int) (*types.Transaction, error) { return _IL2ERC20Gateway.contract.Transact(opts, "withdrawERC20", token, amount, gasLimit) } // WithdrawERC20 is a paid mutator transaction binding the contract method 0x6c07ea43. // // Solidity: function withdrawERC20(address token, uint256 amount, uint256 gasLimit) payable returns() func (_IL2ERC20Gateway *IL2ERC20GatewaySession) WithdrawERC20(token common.Address, amount *big.Int, gasLimit *big.Int) (*types.Transaction, error) { return _IL2ERC20Gateway.Contract.WithdrawERC20(&_IL2ERC20Gateway.TransactOpts, token, amount, gasLimit) } // WithdrawERC20 is a paid mutator transaction binding the contract method 0x6c07ea43. // // Solidity: function withdrawERC20(address token, uint256 amount, uint256 gasLimit) payable returns() func (_IL2ERC20Gateway *IL2ERC20GatewayTransactorSession) WithdrawERC20(token common.Address, amount *big.Int, gasLimit *big.Int) (*types.Transaction, error) { return _IL2ERC20Gateway.Contract.WithdrawERC20(&_IL2ERC20Gateway.TransactOpts, token, amount, gasLimit) } // WithdrawERC200 is a paid mutator transaction binding the contract method 0xa93a4af9. // // Solidity: function withdrawERC20(address token, address to, uint256 amount, uint256 gasLimit) payable returns() func (_IL2ERC20Gateway *IL2ERC20GatewayTransactor) WithdrawERC200(opts *bind.TransactOpts, token common.Address, to common.Address, amount *big.Int, gasLimit *big.Int) (*types.Transaction, error) { return _IL2ERC20Gateway.contract.Transact(opts, "withdrawERC200", token, to, amount, gasLimit) } // WithdrawERC200 is a paid mutator transaction binding the contract method 0xa93a4af9. // // Solidity: function withdrawERC20(address token, address to, uint256 amount, uint256 gasLimit) payable returns() func (_IL2ERC20Gateway *IL2ERC20GatewaySession) WithdrawERC200(token common.Address, to common.Address, amount *big.Int, gasLimit *big.Int) (*types.Transaction, error) { return _IL2ERC20Gateway.Contract.WithdrawERC200(&_IL2ERC20Gateway.TransactOpts, token, to, amount, gasLimit) } // WithdrawERC200 is a paid mutator transaction binding the contract method 0xa93a4af9. // // Solidity: function withdrawERC20(address token, address to, uint256 amount, uint256 gasLimit) payable returns() func (_IL2ERC20Gateway *IL2ERC20GatewayTransactorSession) WithdrawERC200(token common.Address, to common.Address, amount *big.Int, gasLimit *big.Int) (*types.Transaction, error) { return _IL2ERC20Gateway.Contract.WithdrawERC200(&_IL2ERC20Gateway.TransactOpts, token, to, amount, gasLimit) } // WithdrawERC20AndCall is a paid mutator transaction binding the contract method 0x575361b6. // // Solidity: function withdrawERC20AndCall(address token, address to, uint256 amount, bytes data, uint256 gasLimit) payable returns() func (_IL2ERC20Gateway *IL2ERC20GatewayTransactor) WithdrawERC20AndCall(opts *bind.TransactOpts, token common.Address, to common.Address, amount *big.Int, data []byte, gasLimit *big.Int) (*types.Transaction, error) { return _IL2ERC20Gateway.contract.Transact(opts, "withdrawERC20AndCall", token, to, amount, data, gasLimit) } // WithdrawERC20AndCall is a paid mutator transaction binding the contract method 0x575361b6. // // Solidity: function withdrawERC20AndCall(address token, address to, uint256 amount, bytes data, uint256 gasLimit) payable returns() func (_IL2ERC20Gateway *IL2ERC20GatewaySession) WithdrawERC20AndCall(token common.Address, to common.Address, amount *big.Int, data []byte, gasLimit *big.Int) (*types.Transaction, error) { return _IL2ERC20Gateway.Contract.WithdrawERC20AndCall(&_IL2ERC20Gateway.TransactOpts, token, to, amount, data, gasLimit) } // WithdrawERC20AndCall is a paid mutator transaction binding the contract method 0x575361b6. // // Solidity: function withdrawERC20AndCall(address token, address to, uint256 amount, bytes data, uint256 gasLimit) payable returns() func (_IL2ERC20Gateway *IL2ERC20GatewayTransactorSession) WithdrawERC20AndCall(token common.Address, to common.Address, amount *big.Int, data []byte, gasLimit *big.Int) (*types.Transaction, error) { return _IL2ERC20Gateway.Contract.WithdrawERC20AndCall(&_IL2ERC20Gateway.TransactOpts, token, to, amount, data, gasLimit) } // IL2ERC20GatewayFinalizeDepositERC20Iterator is returned from FilterFinalizeDepositERC20 and is used to iterate over the raw logs and unpacked data for FinalizeDepositERC20 events raised by the IL2ERC20Gateway contract. type IL2ERC20GatewayFinalizeDepositERC20Iterator struct { Event *IL2ERC20GatewayFinalizeDepositERC20 // 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 *IL2ERC20GatewayFinalizeDepositERC20Iterator) 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(IL2ERC20GatewayFinalizeDepositERC20) 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(IL2ERC20GatewayFinalizeDepositERC20) 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 *IL2ERC20GatewayFinalizeDepositERC20Iterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. func (it *IL2ERC20GatewayFinalizeDepositERC20Iterator) Close() error { it.sub.Unsubscribe() return nil } // IL2ERC20GatewayFinalizeDepositERC20 represents a FinalizeDepositERC20 event raised by the IL2ERC20Gateway contract. type IL2ERC20GatewayFinalizeDepositERC20 struct { L1Token common.Address L2Token common.Address From common.Address To common.Address Amount *big.Int Data []byte Raw types.Log // Blockchain specific contextual infos } // FilterFinalizeDepositERC20 is a free log retrieval operation binding the contract event 0x165ba69f6ab40c50cade6f65431801e5f9c7d7830b7545391920db039133ba34. // // Solidity: event FinalizeDepositERC20(address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data) func (_IL2ERC20Gateway *IL2ERC20GatewayFilterer) FilterFinalizeDepositERC20(opts *bind.FilterOpts, l1Token []common.Address, l2Token []common.Address, from []common.Address) (*IL2ERC20GatewayFinalizeDepositERC20Iterator, error) { var l1TokenRule []interface{} for _, l1TokenItem := range l1Token { l1TokenRule = append(l1TokenRule, l1TokenItem) } var l2TokenRule []interface{} for _, l2TokenItem := range l2Token { l2TokenRule = append(l2TokenRule, l2TokenItem) } var fromRule []interface{} for _, fromItem := range from { fromRule = append(fromRule, fromItem) } logs, sub, err := _IL2ERC20Gateway.contract.FilterLogs(opts, "FinalizeDepositERC20", l1TokenRule, l2TokenRule, fromRule) if err != nil { return nil, err } return &IL2ERC20GatewayFinalizeDepositERC20Iterator{contract: _IL2ERC20Gateway.contract, event: "FinalizeDepositERC20", logs: logs, sub: sub}, nil } // WatchFinalizeDepositERC20 is a free log subscription operation binding the contract event 0x165ba69f6ab40c50cade6f65431801e5f9c7d7830b7545391920db039133ba34. // // Solidity: event FinalizeDepositERC20(address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data) func (_IL2ERC20Gateway *IL2ERC20GatewayFilterer) WatchFinalizeDepositERC20(opts *bind.WatchOpts, sink chan<- *IL2ERC20GatewayFinalizeDepositERC20, l1Token []common.Address, l2Token []common.Address, from []common.Address) (event.Subscription, error) { var l1TokenRule []interface{} for _, l1TokenItem := range l1Token { l1TokenRule = append(l1TokenRule, l1TokenItem) } var l2TokenRule []interface{} for _, l2TokenItem := range l2Token { l2TokenRule = append(l2TokenRule, l2TokenItem) } var fromRule []interface{} for _, fromItem := range from { fromRule = append(fromRule, fromItem) } logs, sub, err := _IL2ERC20Gateway.contract.WatchLogs(opts, "FinalizeDepositERC20", l1TokenRule, l2TokenRule, fromRule) 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(IL2ERC20GatewayFinalizeDepositERC20) if err := _IL2ERC20Gateway.contract.UnpackLog(event, "FinalizeDepositERC20", 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 } // ParseFinalizeDepositERC20 is a log parse operation binding the contract event 0x165ba69f6ab40c50cade6f65431801e5f9c7d7830b7545391920db039133ba34. // // Solidity: event FinalizeDepositERC20(address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data) func (_IL2ERC20Gateway *IL2ERC20GatewayFilterer) ParseFinalizeDepositERC20(log types.Log) (*IL2ERC20GatewayFinalizeDepositERC20, error) { event := new(IL2ERC20GatewayFinalizeDepositERC20) if err := _IL2ERC20Gateway.contract.UnpackLog(event, "FinalizeDepositERC20", log); err != nil { return nil, err } event.Raw = log return event, nil } // IL2ERC20GatewayWithdrawERC20Iterator is returned from FilterWithdrawERC20 and is used to iterate over the raw logs and unpacked data for WithdrawERC20 events raised by the IL2ERC20Gateway contract. type IL2ERC20GatewayWithdrawERC20Iterator struct { Event *IL2ERC20GatewayWithdrawERC20 // 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 *IL2ERC20GatewayWithdrawERC20Iterator) 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(IL2ERC20GatewayWithdrawERC20) 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(IL2ERC20GatewayWithdrawERC20) 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 *IL2ERC20GatewayWithdrawERC20Iterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. func (it *IL2ERC20GatewayWithdrawERC20Iterator) Close() error { it.sub.Unsubscribe() return nil } // IL2ERC20GatewayWithdrawERC20 represents a WithdrawERC20 event raised by the IL2ERC20Gateway contract. type IL2ERC20GatewayWithdrawERC20 struct { L1Token common.Address L2Token common.Address From common.Address To common.Address Amount *big.Int Data []byte Raw types.Log // Blockchain specific contextual infos } // FilterWithdrawERC20 is a free log retrieval operation binding the contract event 0xd8d3a3f4ab95694bef40475997598bcf8acd3ed9617a4c1013795429414c27e8. // // Solidity: event WithdrawERC20(address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data) func (_IL2ERC20Gateway *IL2ERC20GatewayFilterer) FilterWithdrawERC20(opts *bind.FilterOpts, l1Token []common.Address, l2Token []common.Address, from []common.Address) (*IL2ERC20GatewayWithdrawERC20Iterator, error) { var l1TokenRule []interface{} for _, l1TokenItem := range l1Token { l1TokenRule = append(l1TokenRule, l1TokenItem) } var l2TokenRule []interface{} for _, l2TokenItem := range l2Token { l2TokenRule = append(l2TokenRule, l2TokenItem) } var fromRule []interface{} for _, fromItem := range from { fromRule = append(fromRule, fromItem) } logs, sub, err := _IL2ERC20Gateway.contract.FilterLogs(opts, "WithdrawERC20", l1TokenRule, l2TokenRule, fromRule) if err != nil { return nil, err } return &IL2ERC20GatewayWithdrawERC20Iterator{contract: _IL2ERC20Gateway.contract, event: "WithdrawERC20", logs: logs, sub: sub}, nil } // WatchWithdrawERC20 is a free log subscription operation binding the contract event 0xd8d3a3f4ab95694bef40475997598bcf8acd3ed9617a4c1013795429414c27e8. // // Solidity: event WithdrawERC20(address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data) func (_IL2ERC20Gateway *IL2ERC20GatewayFilterer) WatchWithdrawERC20(opts *bind.WatchOpts, sink chan<- *IL2ERC20GatewayWithdrawERC20, l1Token []common.Address, l2Token []common.Address, from []common.Address) (event.Subscription, error) { var l1TokenRule []interface{} for _, l1TokenItem := range l1Token { l1TokenRule = append(l1TokenRule, l1TokenItem) } var l2TokenRule []interface{} for _, l2TokenItem := range l2Token { l2TokenRule = append(l2TokenRule, l2TokenItem) } var fromRule []interface{} for _, fromItem := range from { fromRule = append(fromRule, fromItem) } logs, sub, err := _IL2ERC20Gateway.contract.WatchLogs(opts, "WithdrawERC20", l1TokenRule, l2TokenRule, fromRule) 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(IL2ERC20GatewayWithdrawERC20) if err := _IL2ERC20Gateway.contract.UnpackLog(event, "WithdrawERC20", 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 } // ParseWithdrawERC20 is a log parse operation binding the contract event 0xd8d3a3f4ab95694bef40475997598bcf8acd3ed9617a4c1013795429414c27e8. // // Solidity: event WithdrawERC20(address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data) func (_IL2ERC20Gateway *IL2ERC20GatewayFilterer) ParseWithdrawERC20(log types.Log) (*IL2ERC20GatewayWithdrawERC20, error) { event := new(IL2ERC20GatewayWithdrawERC20) if err := _IL2ERC20Gateway.contract.UnpackLog(event, "WithdrawERC20", log); err != nil { return nil, err } event.Raw = log return event, nil } // IL2ETHGatewayMetaData contains all meta data concerning the IL2ETHGateway contract. var IL2ETHGatewayMetaData = &bind.MetaData{ ABI: "[{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"FinalizeDepositETH\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"WithdrawETH\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"_data\",\"type\":\"bytes\"}],\"name\":\"finalizeDepositETH\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"}],\"name\":\"withdrawETH\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"}],\"name\":\"withdrawETH\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"}],\"name\":\"withdrawETHAndCall\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"}]", Sigs: map[string]string{ "232e8748": "finalizeDepositETH(address,address,uint256,bytes)", "2fcc29fa": "withdrawETH(address,uint256,uint256)", "c7cdea37": "withdrawETH(uint256,uint256)", "6dc24183": "withdrawETHAndCall(address,uint256,bytes,uint256)", }, } // IL2ETHGatewayABI is the input ABI used to generate the binding from. // Deprecated: Use IL2ETHGatewayMetaData.ABI instead. var IL2ETHGatewayABI = IL2ETHGatewayMetaData.ABI // Deprecated: Use IL2ETHGatewayMetaData.Sigs instead. // IL2ETHGatewayFuncSigs maps the 4-byte function signature to its string representation. var IL2ETHGatewayFuncSigs = IL2ETHGatewayMetaData.Sigs // IL2ETHGateway is an auto generated Go binding around an Ethereum contract. type IL2ETHGateway struct { IL2ETHGatewayCaller // Read-only binding to the contract IL2ETHGatewayTransactor // Write-only binding to the contract IL2ETHGatewayFilterer // Log filterer for contract events } // IL2ETHGatewayCaller is an auto generated read-only Go binding around an Ethereum contract. type IL2ETHGatewayCaller struct { contract *bind.BoundContract // Generic contract wrapper for the low level calls } // IL2ETHGatewayTransactor is an auto generated write-only Go binding around an Ethereum contract. type IL2ETHGatewayTransactor struct { contract *bind.BoundContract // Generic contract wrapper for the low level calls } // IL2ETHGatewayFilterer is an auto generated log filtering Go binding around an Ethereum contract events. type IL2ETHGatewayFilterer struct { contract *bind.BoundContract // Generic contract wrapper for the low level calls } // IL2ETHGatewaySession is an auto generated Go binding around an Ethereum contract, // with pre-set call and transact options. type IL2ETHGatewaySession struct { Contract *IL2ETHGateway // 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 } // IL2ETHGatewayCallerSession is an auto generated read-only Go binding around an Ethereum contract, // with pre-set call options. type IL2ETHGatewayCallerSession struct { Contract *IL2ETHGatewayCaller // Generic contract caller binding to set the session for CallOpts bind.CallOpts // Call options to use throughout this session } // IL2ETHGatewayTransactorSession is an auto generated write-only Go binding around an Ethereum contract, // with pre-set transact options. type IL2ETHGatewayTransactorSession struct { Contract *IL2ETHGatewayTransactor // Generic contract transactor binding to set the session for TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session } // IL2ETHGatewayRaw is an auto generated low-level Go binding around an Ethereum contract. type IL2ETHGatewayRaw struct { Contract *IL2ETHGateway // Generic contract binding to access the raw methods on } // IL2ETHGatewayCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract. type IL2ETHGatewayCallerRaw struct { Contract *IL2ETHGatewayCaller // Generic read-only contract binding to access the raw methods on } // IL2ETHGatewayTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract. type IL2ETHGatewayTransactorRaw struct { Contract *IL2ETHGatewayTransactor // Generic write-only contract binding to access the raw methods on } // NewIL2ETHGateway creates a new instance of IL2ETHGateway, bound to a specific deployed contract. func NewIL2ETHGateway(address common.Address, backend bind.ContractBackend) (*IL2ETHGateway, error) { contract, err := bindIL2ETHGateway(address, backend, backend, backend) if err != nil { return nil, err } return &IL2ETHGateway{IL2ETHGatewayCaller: IL2ETHGatewayCaller{contract: contract}, IL2ETHGatewayTransactor: IL2ETHGatewayTransactor{contract: contract}, IL2ETHGatewayFilterer: IL2ETHGatewayFilterer{contract: contract}}, nil } // NewIL2ETHGatewayCaller creates a new read-only instance of IL2ETHGateway, bound to a specific deployed contract. func NewIL2ETHGatewayCaller(address common.Address, caller bind.ContractCaller) (*IL2ETHGatewayCaller, error) { contract, err := bindIL2ETHGateway(address, caller, nil, nil) if err != nil { return nil, err } return &IL2ETHGatewayCaller{contract: contract}, nil } // NewIL2ETHGatewayTransactor creates a new write-only instance of IL2ETHGateway, bound to a specific deployed contract. func NewIL2ETHGatewayTransactor(address common.Address, transactor bind.ContractTransactor) (*IL2ETHGatewayTransactor, error) { contract, err := bindIL2ETHGateway(address, nil, transactor, nil) if err != nil { return nil, err } return &IL2ETHGatewayTransactor{contract: contract}, nil } // NewIL2ETHGatewayFilterer creates a new log filterer instance of IL2ETHGateway, bound to a specific deployed contract. func NewIL2ETHGatewayFilterer(address common.Address, filterer bind.ContractFilterer) (*IL2ETHGatewayFilterer, error) { contract, err := bindIL2ETHGateway(address, nil, nil, filterer) if err != nil { return nil, err } return &IL2ETHGatewayFilterer{contract: contract}, nil } // bindIL2ETHGateway binds a generic wrapper to an already deployed contract. func bindIL2ETHGateway(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { parsed, err := IL2ETHGatewayMetaData.GetAbi() 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 (_IL2ETHGateway *IL2ETHGatewayRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { return _IL2ETHGateway.Contract.IL2ETHGatewayCaller.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 (_IL2ETHGateway *IL2ETHGatewayRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { return _IL2ETHGateway.Contract.IL2ETHGatewayTransactor.contract.Transfer(opts) } // Transact invokes the (paid) contract method with params as input values. func (_IL2ETHGateway *IL2ETHGatewayRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { return _IL2ETHGateway.Contract.IL2ETHGatewayTransactor.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 (_IL2ETHGateway *IL2ETHGatewayCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { return _IL2ETHGateway.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 (_IL2ETHGateway *IL2ETHGatewayTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { return _IL2ETHGateway.Contract.contract.Transfer(opts) } // Transact invokes the (paid) contract method with params as input values. func (_IL2ETHGateway *IL2ETHGatewayTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { return _IL2ETHGateway.Contract.contract.Transact(opts, method, params...) } // FinalizeDepositETH is a paid mutator transaction binding the contract method 0x232e8748. // // Solidity: function finalizeDepositETH(address _from, address _to, uint256 _amount, bytes _data) payable returns() func (_IL2ETHGateway *IL2ETHGatewayTransactor) FinalizeDepositETH(opts *bind.TransactOpts, _from common.Address, _to common.Address, _amount *big.Int, _data []byte) (*types.Transaction, error) { return _IL2ETHGateway.contract.Transact(opts, "finalizeDepositETH", _from, _to, _amount, _data) } // FinalizeDepositETH is a paid mutator transaction binding the contract method 0x232e8748. // // Solidity: function finalizeDepositETH(address _from, address _to, uint256 _amount, bytes _data) payable returns() func (_IL2ETHGateway *IL2ETHGatewaySession) FinalizeDepositETH(_from common.Address, _to common.Address, _amount *big.Int, _data []byte) (*types.Transaction, error) { return _IL2ETHGateway.Contract.FinalizeDepositETH(&_IL2ETHGateway.TransactOpts, _from, _to, _amount, _data) } // FinalizeDepositETH is a paid mutator transaction binding the contract method 0x232e8748. // // Solidity: function finalizeDepositETH(address _from, address _to, uint256 _amount, bytes _data) payable returns() func (_IL2ETHGateway *IL2ETHGatewayTransactorSession) FinalizeDepositETH(_from common.Address, _to common.Address, _amount *big.Int, _data []byte) (*types.Transaction, error) { return _IL2ETHGateway.Contract.FinalizeDepositETH(&_IL2ETHGateway.TransactOpts, _from, _to, _amount, _data) } // WithdrawETH is a paid mutator transaction binding the contract method 0x2fcc29fa. // // Solidity: function withdrawETH(address to, uint256 amount, uint256 gasLimit) payable returns() func (_IL2ETHGateway *IL2ETHGatewayTransactor) WithdrawETH(opts *bind.TransactOpts, to common.Address, amount *big.Int, gasLimit *big.Int) (*types.Transaction, error) { return _IL2ETHGateway.contract.Transact(opts, "withdrawETH", to, amount, gasLimit) } // WithdrawETH is a paid mutator transaction binding the contract method 0x2fcc29fa. // // Solidity: function withdrawETH(address to, uint256 amount, uint256 gasLimit) payable returns() func (_IL2ETHGateway *IL2ETHGatewaySession) WithdrawETH(to common.Address, amount *big.Int, gasLimit *big.Int) (*types.Transaction, error) { return _IL2ETHGateway.Contract.WithdrawETH(&_IL2ETHGateway.TransactOpts, to, amount, gasLimit) } // WithdrawETH is a paid mutator transaction binding the contract method 0x2fcc29fa. // // Solidity: function withdrawETH(address to, uint256 amount, uint256 gasLimit) payable returns() func (_IL2ETHGateway *IL2ETHGatewayTransactorSession) WithdrawETH(to common.Address, amount *big.Int, gasLimit *big.Int) (*types.Transaction, error) { return _IL2ETHGateway.Contract.WithdrawETH(&_IL2ETHGateway.TransactOpts, to, amount, gasLimit) } // WithdrawETH0 is a paid mutator transaction binding the contract method 0xc7cdea37. // // Solidity: function withdrawETH(uint256 amount, uint256 gasLimit) payable returns() func (_IL2ETHGateway *IL2ETHGatewayTransactor) WithdrawETH0(opts *bind.TransactOpts, amount *big.Int, gasLimit *big.Int) (*types.Transaction, error) { return _IL2ETHGateway.contract.Transact(opts, "withdrawETH0", amount, gasLimit) } // WithdrawETH0 is a paid mutator transaction binding the contract method 0xc7cdea37. // // Solidity: function withdrawETH(uint256 amount, uint256 gasLimit) payable returns() func (_IL2ETHGateway *IL2ETHGatewaySession) WithdrawETH0(amount *big.Int, gasLimit *big.Int) (*types.Transaction, error) { return _IL2ETHGateway.Contract.WithdrawETH0(&_IL2ETHGateway.TransactOpts, amount, gasLimit) } // WithdrawETH0 is a paid mutator transaction binding the contract method 0xc7cdea37. // // Solidity: function withdrawETH(uint256 amount, uint256 gasLimit) payable returns() func (_IL2ETHGateway *IL2ETHGatewayTransactorSession) WithdrawETH0(amount *big.Int, gasLimit *big.Int) (*types.Transaction, error) { return _IL2ETHGateway.Contract.WithdrawETH0(&_IL2ETHGateway.TransactOpts, amount, gasLimit) } // WithdrawETHAndCall is a paid mutator transaction binding the contract method 0x6dc24183. // // Solidity: function withdrawETHAndCall(address to, uint256 amount, bytes data, uint256 gasLimit) payable returns() func (_IL2ETHGateway *IL2ETHGatewayTransactor) WithdrawETHAndCall(opts *bind.TransactOpts, to common.Address, amount *big.Int, data []byte, gasLimit *big.Int) (*types.Transaction, error) { return _IL2ETHGateway.contract.Transact(opts, "withdrawETHAndCall", to, amount, data, gasLimit) } // WithdrawETHAndCall is a paid mutator transaction binding the contract method 0x6dc24183. // // Solidity: function withdrawETHAndCall(address to, uint256 amount, bytes data, uint256 gasLimit) payable returns() func (_IL2ETHGateway *IL2ETHGatewaySession) WithdrawETHAndCall(to common.Address, amount *big.Int, data []byte, gasLimit *big.Int) (*types.Transaction, error) { return _IL2ETHGateway.Contract.WithdrawETHAndCall(&_IL2ETHGateway.TransactOpts, to, amount, data, gasLimit) } // WithdrawETHAndCall is a paid mutator transaction binding the contract method 0x6dc24183. // // Solidity: function withdrawETHAndCall(address to, uint256 amount, bytes data, uint256 gasLimit) payable returns() func (_IL2ETHGateway *IL2ETHGatewayTransactorSession) WithdrawETHAndCall(to common.Address, amount *big.Int, data []byte, gasLimit *big.Int) (*types.Transaction, error) { return _IL2ETHGateway.Contract.WithdrawETHAndCall(&_IL2ETHGateway.TransactOpts, to, amount, data, gasLimit) } // IL2ETHGatewayFinalizeDepositETHIterator is returned from FilterFinalizeDepositETH and is used to iterate over the raw logs and unpacked data for FinalizeDepositETH events raised by the IL2ETHGateway contract. type IL2ETHGatewayFinalizeDepositETHIterator struct { Event *IL2ETHGatewayFinalizeDepositETH // 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 *IL2ETHGatewayFinalizeDepositETHIterator) 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(IL2ETHGatewayFinalizeDepositETH) 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(IL2ETHGatewayFinalizeDepositETH) 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 *IL2ETHGatewayFinalizeDepositETHIterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. func (it *IL2ETHGatewayFinalizeDepositETHIterator) Close() error { it.sub.Unsubscribe() return nil } // IL2ETHGatewayFinalizeDepositETH represents a FinalizeDepositETH event raised by the IL2ETHGateway contract. type IL2ETHGatewayFinalizeDepositETH struct { From common.Address To common.Address Amount *big.Int Data []byte Raw types.Log // Blockchain specific contextual infos } // FilterFinalizeDepositETH is a free log retrieval operation binding the contract event 0x9e86c356e14e24e26e3ce769bf8b87de38e0faa0ed0ca946fa09659aa606bd2d. // // Solidity: event FinalizeDepositETH(address indexed from, address indexed to, uint256 amount, bytes data) func (_IL2ETHGateway *IL2ETHGatewayFilterer) FilterFinalizeDepositETH(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*IL2ETHGatewayFinalizeDepositETHIterator, error) { var fromRule []interface{} for _, fromItem := range from { fromRule = append(fromRule, fromItem) } var toRule []interface{} for _, toItem := range to { toRule = append(toRule, toItem) } logs, sub, err := _IL2ETHGateway.contract.FilterLogs(opts, "FinalizeDepositETH", fromRule, toRule) if err != nil { return nil, err } return &IL2ETHGatewayFinalizeDepositETHIterator{contract: _IL2ETHGateway.contract, event: "FinalizeDepositETH", logs: logs, sub: sub}, nil } // WatchFinalizeDepositETH is a free log subscription operation binding the contract event 0x9e86c356e14e24e26e3ce769bf8b87de38e0faa0ed0ca946fa09659aa606bd2d. // // Solidity: event FinalizeDepositETH(address indexed from, address indexed to, uint256 amount, bytes data) func (_IL2ETHGateway *IL2ETHGatewayFilterer) WatchFinalizeDepositETH(opts *bind.WatchOpts, sink chan<- *IL2ETHGatewayFinalizeDepositETH, from []common.Address, to []common.Address) (event.Subscription, error) { var fromRule []interface{} for _, fromItem := range from { fromRule = append(fromRule, fromItem) } var toRule []interface{} for _, toItem := range to { toRule = append(toRule, toItem) } logs, sub, err := _IL2ETHGateway.contract.WatchLogs(opts, "FinalizeDepositETH", fromRule, toRule) 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(IL2ETHGatewayFinalizeDepositETH) if err := _IL2ETHGateway.contract.UnpackLog(event, "FinalizeDepositETH", 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 } // ParseFinalizeDepositETH is a log parse operation binding the contract event 0x9e86c356e14e24e26e3ce769bf8b87de38e0faa0ed0ca946fa09659aa606bd2d. // // Solidity: event FinalizeDepositETH(address indexed from, address indexed to, uint256 amount, bytes data) func (_IL2ETHGateway *IL2ETHGatewayFilterer) ParseFinalizeDepositETH(log types.Log) (*IL2ETHGatewayFinalizeDepositETH, error) { event := new(IL2ETHGatewayFinalizeDepositETH) if err := _IL2ETHGateway.contract.UnpackLog(event, "FinalizeDepositETH", log); err != nil { return nil, err } event.Raw = log return event, nil } // IL2ETHGatewayWithdrawETHIterator is returned from FilterWithdrawETH and is used to iterate over the raw logs and unpacked data for WithdrawETH events raised by the IL2ETHGateway contract. type IL2ETHGatewayWithdrawETHIterator struct { Event *IL2ETHGatewayWithdrawETH // 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 *IL2ETHGatewayWithdrawETHIterator) 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(IL2ETHGatewayWithdrawETH) 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(IL2ETHGatewayWithdrawETH) 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 *IL2ETHGatewayWithdrawETHIterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. func (it *IL2ETHGatewayWithdrawETHIterator) Close() error { it.sub.Unsubscribe() return nil } // IL2ETHGatewayWithdrawETH represents a WithdrawETH event raised by the IL2ETHGateway contract. type IL2ETHGatewayWithdrawETH struct { From common.Address To common.Address Amount *big.Int Data []byte Raw types.Log // Blockchain specific contextual infos } // FilterWithdrawETH is a free log retrieval operation binding the contract event 0xd8ed6eaa9a7a8980d7901e911fde6686810b989d3082182d1d3a3df6306ce20e. // // Solidity: event WithdrawETH(address indexed from, address indexed to, uint256 amount, bytes data) func (_IL2ETHGateway *IL2ETHGatewayFilterer) FilterWithdrawETH(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*IL2ETHGatewayWithdrawETHIterator, error) { var fromRule []interface{} for _, fromItem := range from { fromRule = append(fromRule, fromItem) } var toRule []interface{} for _, toItem := range to { toRule = append(toRule, toItem) } logs, sub, err := _IL2ETHGateway.contract.FilterLogs(opts, "WithdrawETH", fromRule, toRule) if err != nil { return nil, err } return &IL2ETHGatewayWithdrawETHIterator{contract: _IL2ETHGateway.contract, event: "WithdrawETH", logs: logs, sub: sub}, nil } // WatchWithdrawETH is a free log subscription operation binding the contract event 0xd8ed6eaa9a7a8980d7901e911fde6686810b989d3082182d1d3a3df6306ce20e. // // Solidity: event WithdrawETH(address indexed from, address indexed to, uint256 amount, bytes data) func (_IL2ETHGateway *IL2ETHGatewayFilterer) WatchWithdrawETH(opts *bind.WatchOpts, sink chan<- *IL2ETHGatewayWithdrawETH, from []common.Address, to []common.Address) (event.Subscription, error) { var fromRule []interface{} for _, fromItem := range from { fromRule = append(fromRule, fromItem) } var toRule []interface{} for _, toItem := range to { toRule = append(toRule, toItem) } logs, sub, err := _IL2ETHGateway.contract.WatchLogs(opts, "WithdrawETH", fromRule, toRule) 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(IL2ETHGatewayWithdrawETH) if err := _IL2ETHGateway.contract.UnpackLog(event, "WithdrawETH", 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 } // ParseWithdrawETH is a log parse operation binding the contract event 0xd8ed6eaa9a7a8980d7901e911fde6686810b989d3082182d1d3a3df6306ce20e. // // Solidity: event WithdrawETH(address indexed from, address indexed to, uint256 amount, bytes data) func (_IL2ETHGateway *IL2ETHGatewayFilterer) ParseWithdrawETH(log types.Log) (*IL2ETHGatewayWithdrawETH, error) { event := new(IL2ETHGatewayWithdrawETH) if err := _IL2ETHGateway.contract.UnpackLog(event, "WithdrawETH", log); err != nil { return nil, err } event.Raw = log return event, nil } // IL2GatewayRouterMetaData contains all meta data concerning the IL2GatewayRouter contract. var IL2GatewayRouterMetaData = &bind.MetaData{ ABI: "[{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"l1Token\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"l2Token\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"FinalizeDepositERC20\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"FinalizeDepositETH\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oldDefaultERC20Gateway\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"newDefaultERC20Gateway\",\"type\":\"address\"}],\"name\":\"SetDefaultERC20Gateway\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oldGateway\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"newGateway\",\"type\":\"address\"}],\"name\":\"SetERC20Gateway\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oldETHGateway\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"newEthGateway\",\"type\":\"address\"}],\"name\":\"SetETHGateway\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"l1Token\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"l2Token\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"WithdrawERC20\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"WithdrawETH\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"l1Token\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"l2Token\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"finalizeDepositERC20\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"_data\",\"type\":\"bytes\"}],\"name\":\"finalizeDepositETH\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"l2Token\",\"type\":\"address\"}],\"name\":\"getL1ERC20Address\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"l1Token\",\"type\":\"address\"}],\"name\":\"getL2ERC20Address\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_newDefaultERC20Gateway\",\"type\":\"address\"}],\"name\":\"setDefaultERC20Gateway\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_tokens\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_gateways\",\"type\":\"address[]\"}],\"name\":\"setERC20Gateway\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_newEthGateway\",\"type\":\"address\"}],\"name\":\"setETHGateway\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"}],\"name\":\"withdrawERC20\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"}],\"name\":\"withdrawERC20\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"}],\"name\":\"withdrawERC20AndCall\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"}],\"name\":\"withdrawETH\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"}],\"name\":\"withdrawETH\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"}],\"name\":\"withdrawETHAndCall\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"}]", Sigs: map[string]string{ "8431f5c1": "finalizeDepositERC20(address,address,address,address,uint256,bytes)", "232e8748": "finalizeDepositETH(address,address,uint256,bytes)", "54bbd59c": "getL1ERC20Address(address)", "c676ad29": "getL2ERC20Address(address)", "5dfd5b9a": "setDefaultERC20Gateway(address)", "635c8637": "setERC20Gateway(address[],address[])", "3d1d31c7": "setETHGateway(address)", "a93a4af9": "withdrawERC20(address,address,uint256,uint256)", "6c07ea43": "withdrawERC20(address,uint256,uint256)", "575361b6": "withdrawERC20AndCall(address,address,uint256,bytes,uint256)", "2fcc29fa": "withdrawETH(address,uint256,uint256)", "c7cdea37": "withdrawETH(uint256,uint256)", "6dc24183": "withdrawETHAndCall(address,uint256,bytes,uint256)", }, } // IL2GatewayRouterABI is the input ABI used to generate the binding from. // Deprecated: Use IL2GatewayRouterMetaData.ABI instead. var IL2GatewayRouterABI = IL2GatewayRouterMetaData.ABI // Deprecated: Use IL2GatewayRouterMetaData.Sigs instead. // IL2GatewayRouterFuncSigs maps the 4-byte function signature to its string representation. var IL2GatewayRouterFuncSigs = IL2GatewayRouterMetaData.Sigs // IL2GatewayRouter is an auto generated Go binding around an Ethereum contract. type IL2GatewayRouter struct { IL2GatewayRouterCaller // Read-only binding to the contract IL2GatewayRouterTransactor // Write-only binding to the contract IL2GatewayRouterFilterer // Log filterer for contract events } // IL2GatewayRouterCaller is an auto generated read-only Go binding around an Ethereum contract. type IL2GatewayRouterCaller struct { contract *bind.BoundContract // Generic contract wrapper for the low level calls } // IL2GatewayRouterTransactor is an auto generated write-only Go binding around an Ethereum contract. type IL2GatewayRouterTransactor struct { contract *bind.BoundContract // Generic contract wrapper for the low level calls } // IL2GatewayRouterFilterer is an auto generated log filtering Go binding around an Ethereum contract events. type IL2GatewayRouterFilterer struct { contract *bind.BoundContract // Generic contract wrapper for the low level calls } // IL2GatewayRouterSession is an auto generated Go binding around an Ethereum contract, // with pre-set call and transact options. type IL2GatewayRouterSession struct { Contract *IL2GatewayRouter // 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 } // IL2GatewayRouterCallerSession is an auto generated read-only Go binding around an Ethereum contract, // with pre-set call options. type IL2GatewayRouterCallerSession struct { Contract *IL2GatewayRouterCaller // Generic contract caller binding to set the session for CallOpts bind.CallOpts // Call options to use throughout this session } // IL2GatewayRouterTransactorSession is an auto generated write-only Go binding around an Ethereum contract, // with pre-set transact options. type IL2GatewayRouterTransactorSession struct { Contract *IL2GatewayRouterTransactor // Generic contract transactor binding to set the session for TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session } // IL2GatewayRouterRaw is an auto generated low-level Go binding around an Ethereum contract. type IL2GatewayRouterRaw struct { Contract *IL2GatewayRouter // Generic contract binding to access the raw methods on } // IL2GatewayRouterCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract. type IL2GatewayRouterCallerRaw struct { Contract *IL2GatewayRouterCaller // Generic read-only contract binding to access the raw methods on } // IL2GatewayRouterTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract. type IL2GatewayRouterTransactorRaw struct { Contract *IL2GatewayRouterTransactor // Generic write-only contract binding to access the raw methods on } // NewIL2GatewayRouter creates a new instance of IL2GatewayRouter, bound to a specific deployed contract. func NewIL2GatewayRouter(address common.Address, backend bind.ContractBackend) (*IL2GatewayRouter, error) { contract, err := bindIL2GatewayRouter(address, backend, backend, backend) if err != nil { return nil, err } return &IL2GatewayRouter{IL2GatewayRouterCaller: IL2GatewayRouterCaller{contract: contract}, IL2GatewayRouterTransactor: IL2GatewayRouterTransactor{contract: contract}, IL2GatewayRouterFilterer: IL2GatewayRouterFilterer{contract: contract}}, nil } // NewIL2GatewayRouterCaller creates a new read-only instance of IL2GatewayRouter, bound to a specific deployed contract. func NewIL2GatewayRouterCaller(address common.Address, caller bind.ContractCaller) (*IL2GatewayRouterCaller, error) { contract, err := bindIL2GatewayRouter(address, caller, nil, nil) if err != nil { return nil, err } return &IL2GatewayRouterCaller{contract: contract}, nil } // NewIL2GatewayRouterTransactor creates a new write-only instance of IL2GatewayRouter, bound to a specific deployed contract. func NewIL2GatewayRouterTransactor(address common.Address, transactor bind.ContractTransactor) (*IL2GatewayRouterTransactor, error) { contract, err := bindIL2GatewayRouter(address, nil, transactor, nil) if err != nil { return nil, err } return &IL2GatewayRouterTransactor{contract: contract}, nil } // NewIL2GatewayRouterFilterer creates a new log filterer instance of IL2GatewayRouter, bound to a specific deployed contract. func NewIL2GatewayRouterFilterer(address common.Address, filterer bind.ContractFilterer) (*IL2GatewayRouterFilterer, error) { contract, err := bindIL2GatewayRouter(address, nil, nil, filterer) if err != nil { return nil, err } return &IL2GatewayRouterFilterer{contract: contract}, nil } // bindIL2GatewayRouter binds a generic wrapper to an already deployed contract. func bindIL2GatewayRouter(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { parsed, err := IL2GatewayRouterMetaData.GetAbi() 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 (_IL2GatewayRouter *IL2GatewayRouterRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { return _IL2GatewayRouter.Contract.IL2GatewayRouterCaller.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 (_IL2GatewayRouter *IL2GatewayRouterRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.IL2GatewayRouterTransactor.contract.Transfer(opts) } // Transact invokes the (paid) contract method with params as input values. func (_IL2GatewayRouter *IL2GatewayRouterRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.IL2GatewayRouterTransactor.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 (_IL2GatewayRouter *IL2GatewayRouterCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { return _IL2GatewayRouter.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 (_IL2GatewayRouter *IL2GatewayRouterTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.contract.Transfer(opts) } // Transact invokes the (paid) contract method with params as input values. func (_IL2GatewayRouter *IL2GatewayRouterTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.contract.Transact(opts, method, params...) } // GetL1ERC20Address is a free data retrieval call binding the contract method 0x54bbd59c. // // Solidity: function getL1ERC20Address(address l2Token) view returns(address) func (_IL2GatewayRouter *IL2GatewayRouterCaller) GetL1ERC20Address(opts *bind.CallOpts, l2Token common.Address) (common.Address, error) { var out []interface{} err := _IL2GatewayRouter.contract.Call(opts, &out, "getL1ERC20Address", l2Token) if err != nil { return *new(common.Address), err } out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) return out0, err } // GetL1ERC20Address is a free data retrieval call binding the contract method 0x54bbd59c. // // Solidity: function getL1ERC20Address(address l2Token) view returns(address) func (_IL2GatewayRouter *IL2GatewayRouterSession) GetL1ERC20Address(l2Token common.Address) (common.Address, error) { return _IL2GatewayRouter.Contract.GetL1ERC20Address(&_IL2GatewayRouter.CallOpts, l2Token) } // GetL1ERC20Address is a free data retrieval call binding the contract method 0x54bbd59c. // // Solidity: function getL1ERC20Address(address l2Token) view returns(address) func (_IL2GatewayRouter *IL2GatewayRouterCallerSession) GetL1ERC20Address(l2Token common.Address) (common.Address, error) { return _IL2GatewayRouter.Contract.GetL1ERC20Address(&_IL2GatewayRouter.CallOpts, l2Token) } // GetL2ERC20Address is a free data retrieval call binding the contract method 0xc676ad29. // // Solidity: function getL2ERC20Address(address l1Token) view returns(address) func (_IL2GatewayRouter *IL2GatewayRouterCaller) GetL2ERC20Address(opts *bind.CallOpts, l1Token common.Address) (common.Address, error) { var out []interface{} err := _IL2GatewayRouter.contract.Call(opts, &out, "getL2ERC20Address", l1Token) if err != nil { return *new(common.Address), err } out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) return out0, err } // GetL2ERC20Address is a free data retrieval call binding the contract method 0xc676ad29. // // Solidity: function getL2ERC20Address(address l1Token) view returns(address) func (_IL2GatewayRouter *IL2GatewayRouterSession) GetL2ERC20Address(l1Token common.Address) (common.Address, error) { return _IL2GatewayRouter.Contract.GetL2ERC20Address(&_IL2GatewayRouter.CallOpts, l1Token) } // GetL2ERC20Address is a free data retrieval call binding the contract method 0xc676ad29. // // Solidity: function getL2ERC20Address(address l1Token) view returns(address) func (_IL2GatewayRouter *IL2GatewayRouterCallerSession) GetL2ERC20Address(l1Token common.Address) (common.Address, error) { return _IL2GatewayRouter.Contract.GetL2ERC20Address(&_IL2GatewayRouter.CallOpts, l1Token) } // FinalizeDepositERC20 is a paid mutator transaction binding the contract method 0x8431f5c1. // // Solidity: function finalizeDepositERC20(address l1Token, address l2Token, address from, address to, uint256 amount, bytes data) payable returns() func (_IL2GatewayRouter *IL2GatewayRouterTransactor) FinalizeDepositERC20(opts *bind.TransactOpts, l1Token common.Address, l2Token common.Address, from common.Address, to common.Address, amount *big.Int, data []byte) (*types.Transaction, error) { return _IL2GatewayRouter.contract.Transact(opts, "finalizeDepositERC20", l1Token, l2Token, from, to, amount, data) } // FinalizeDepositERC20 is a paid mutator transaction binding the contract method 0x8431f5c1. // // Solidity: function finalizeDepositERC20(address l1Token, address l2Token, address from, address to, uint256 amount, bytes data) payable returns() func (_IL2GatewayRouter *IL2GatewayRouterSession) FinalizeDepositERC20(l1Token common.Address, l2Token common.Address, from common.Address, to common.Address, amount *big.Int, data []byte) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.FinalizeDepositERC20(&_IL2GatewayRouter.TransactOpts, l1Token, l2Token, from, to, amount, data) } // FinalizeDepositERC20 is a paid mutator transaction binding the contract method 0x8431f5c1. // // Solidity: function finalizeDepositERC20(address l1Token, address l2Token, address from, address to, uint256 amount, bytes data) payable returns() func (_IL2GatewayRouter *IL2GatewayRouterTransactorSession) FinalizeDepositERC20(l1Token common.Address, l2Token common.Address, from common.Address, to common.Address, amount *big.Int, data []byte) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.FinalizeDepositERC20(&_IL2GatewayRouter.TransactOpts, l1Token, l2Token, from, to, amount, data) } // FinalizeDepositETH is a paid mutator transaction binding the contract method 0x232e8748. // // Solidity: function finalizeDepositETH(address _from, address _to, uint256 _amount, bytes _data) payable returns() func (_IL2GatewayRouter *IL2GatewayRouterTransactor) FinalizeDepositETH(opts *bind.TransactOpts, _from common.Address, _to common.Address, _amount *big.Int, _data []byte) (*types.Transaction, error) { return _IL2GatewayRouter.contract.Transact(opts, "finalizeDepositETH", _from, _to, _amount, _data) } // FinalizeDepositETH is a paid mutator transaction binding the contract method 0x232e8748. // // Solidity: function finalizeDepositETH(address _from, address _to, uint256 _amount, bytes _data) payable returns() func (_IL2GatewayRouter *IL2GatewayRouterSession) FinalizeDepositETH(_from common.Address, _to common.Address, _amount *big.Int, _data []byte) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.FinalizeDepositETH(&_IL2GatewayRouter.TransactOpts, _from, _to, _amount, _data) } // FinalizeDepositETH is a paid mutator transaction binding the contract method 0x232e8748. // // Solidity: function finalizeDepositETH(address _from, address _to, uint256 _amount, bytes _data) payable returns() func (_IL2GatewayRouter *IL2GatewayRouterTransactorSession) FinalizeDepositETH(_from common.Address, _to common.Address, _amount *big.Int, _data []byte) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.FinalizeDepositETH(&_IL2GatewayRouter.TransactOpts, _from, _to, _amount, _data) } // SetDefaultERC20Gateway is a paid mutator transaction binding the contract method 0x5dfd5b9a. // // Solidity: function setDefaultERC20Gateway(address _newDefaultERC20Gateway) returns() func (_IL2GatewayRouter *IL2GatewayRouterTransactor) SetDefaultERC20Gateway(opts *bind.TransactOpts, _newDefaultERC20Gateway common.Address) (*types.Transaction, error) { return _IL2GatewayRouter.contract.Transact(opts, "setDefaultERC20Gateway", _newDefaultERC20Gateway) } // SetDefaultERC20Gateway is a paid mutator transaction binding the contract method 0x5dfd5b9a. // // Solidity: function setDefaultERC20Gateway(address _newDefaultERC20Gateway) returns() func (_IL2GatewayRouter *IL2GatewayRouterSession) SetDefaultERC20Gateway(_newDefaultERC20Gateway common.Address) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.SetDefaultERC20Gateway(&_IL2GatewayRouter.TransactOpts, _newDefaultERC20Gateway) } // SetDefaultERC20Gateway is a paid mutator transaction binding the contract method 0x5dfd5b9a. // // Solidity: function setDefaultERC20Gateway(address _newDefaultERC20Gateway) returns() func (_IL2GatewayRouter *IL2GatewayRouterTransactorSession) SetDefaultERC20Gateway(_newDefaultERC20Gateway common.Address) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.SetDefaultERC20Gateway(&_IL2GatewayRouter.TransactOpts, _newDefaultERC20Gateway) } // SetERC20Gateway is a paid mutator transaction binding the contract method 0x635c8637. // // Solidity: function setERC20Gateway(address[] _tokens, address[] _gateways) returns() func (_IL2GatewayRouter *IL2GatewayRouterTransactor) SetERC20Gateway(opts *bind.TransactOpts, _tokens []common.Address, _gateways []common.Address) (*types.Transaction, error) { return _IL2GatewayRouter.contract.Transact(opts, "setERC20Gateway", _tokens, _gateways) } // SetERC20Gateway is a paid mutator transaction binding the contract method 0x635c8637. // // Solidity: function setERC20Gateway(address[] _tokens, address[] _gateways) returns() func (_IL2GatewayRouter *IL2GatewayRouterSession) SetERC20Gateway(_tokens []common.Address, _gateways []common.Address) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.SetERC20Gateway(&_IL2GatewayRouter.TransactOpts, _tokens, _gateways) } // SetERC20Gateway is a paid mutator transaction binding the contract method 0x635c8637. // // Solidity: function setERC20Gateway(address[] _tokens, address[] _gateways) returns() func (_IL2GatewayRouter *IL2GatewayRouterTransactorSession) SetERC20Gateway(_tokens []common.Address, _gateways []common.Address) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.SetERC20Gateway(&_IL2GatewayRouter.TransactOpts, _tokens, _gateways) } // SetETHGateway is a paid mutator transaction binding the contract method 0x3d1d31c7. // // Solidity: function setETHGateway(address _newEthGateway) returns() func (_IL2GatewayRouter *IL2GatewayRouterTransactor) SetETHGateway(opts *bind.TransactOpts, _newEthGateway common.Address) (*types.Transaction, error) { return _IL2GatewayRouter.contract.Transact(opts, "setETHGateway", _newEthGateway) } // SetETHGateway is a paid mutator transaction binding the contract method 0x3d1d31c7. // // Solidity: function setETHGateway(address _newEthGateway) returns() func (_IL2GatewayRouter *IL2GatewayRouterSession) SetETHGateway(_newEthGateway common.Address) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.SetETHGateway(&_IL2GatewayRouter.TransactOpts, _newEthGateway) } // SetETHGateway is a paid mutator transaction binding the contract method 0x3d1d31c7. // // Solidity: function setETHGateway(address _newEthGateway) returns() func (_IL2GatewayRouter *IL2GatewayRouterTransactorSession) SetETHGateway(_newEthGateway common.Address) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.SetETHGateway(&_IL2GatewayRouter.TransactOpts, _newEthGateway) } // WithdrawERC20 is a paid mutator transaction binding the contract method 0x6c07ea43. // // Solidity: function withdrawERC20(address token, uint256 amount, uint256 gasLimit) payable returns() func (_IL2GatewayRouter *IL2GatewayRouterTransactor) WithdrawERC20(opts *bind.TransactOpts, token common.Address, amount *big.Int, gasLimit *big.Int) (*types.Transaction, error) { return _IL2GatewayRouter.contract.Transact(opts, "withdrawERC20", token, amount, gasLimit) } // WithdrawERC20 is a paid mutator transaction binding the contract method 0x6c07ea43. // // Solidity: function withdrawERC20(address token, uint256 amount, uint256 gasLimit) payable returns() func (_IL2GatewayRouter *IL2GatewayRouterSession) WithdrawERC20(token common.Address, amount *big.Int, gasLimit *big.Int) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.WithdrawERC20(&_IL2GatewayRouter.TransactOpts, token, amount, gasLimit) } // WithdrawERC20 is a paid mutator transaction binding the contract method 0x6c07ea43. // // Solidity: function withdrawERC20(address token, uint256 amount, uint256 gasLimit) payable returns() func (_IL2GatewayRouter *IL2GatewayRouterTransactorSession) WithdrawERC20(token common.Address, amount *big.Int, gasLimit *big.Int) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.WithdrawERC20(&_IL2GatewayRouter.TransactOpts, token, amount, gasLimit) } // WithdrawERC200 is a paid mutator transaction binding the contract method 0xa93a4af9. // // Solidity: function withdrawERC20(address token, address to, uint256 amount, uint256 gasLimit) payable returns() func (_IL2GatewayRouter *IL2GatewayRouterTransactor) WithdrawERC200(opts *bind.TransactOpts, token common.Address, to common.Address, amount *big.Int, gasLimit *big.Int) (*types.Transaction, error) { return _IL2GatewayRouter.contract.Transact(opts, "withdrawERC200", token, to, amount, gasLimit) } // WithdrawERC200 is a paid mutator transaction binding the contract method 0xa93a4af9. // // Solidity: function withdrawERC20(address token, address to, uint256 amount, uint256 gasLimit) payable returns() func (_IL2GatewayRouter *IL2GatewayRouterSession) WithdrawERC200(token common.Address, to common.Address, amount *big.Int, gasLimit *big.Int) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.WithdrawERC200(&_IL2GatewayRouter.TransactOpts, token, to, amount, gasLimit) } // WithdrawERC200 is a paid mutator transaction binding the contract method 0xa93a4af9. // // Solidity: function withdrawERC20(address token, address to, uint256 amount, uint256 gasLimit) payable returns() func (_IL2GatewayRouter *IL2GatewayRouterTransactorSession) WithdrawERC200(token common.Address, to common.Address, amount *big.Int, gasLimit *big.Int) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.WithdrawERC200(&_IL2GatewayRouter.TransactOpts, token, to, amount, gasLimit) } // WithdrawERC20AndCall is a paid mutator transaction binding the contract method 0x575361b6. // // Solidity: function withdrawERC20AndCall(address token, address to, uint256 amount, bytes data, uint256 gasLimit) payable returns() func (_IL2GatewayRouter *IL2GatewayRouterTransactor) WithdrawERC20AndCall(opts *bind.TransactOpts, token common.Address, to common.Address, amount *big.Int, data []byte, gasLimit *big.Int) (*types.Transaction, error) { return _IL2GatewayRouter.contract.Transact(opts, "withdrawERC20AndCall", token, to, amount, data, gasLimit) } // WithdrawERC20AndCall is a paid mutator transaction binding the contract method 0x575361b6. // // Solidity: function withdrawERC20AndCall(address token, address to, uint256 amount, bytes data, uint256 gasLimit) payable returns() func (_IL2GatewayRouter *IL2GatewayRouterSession) WithdrawERC20AndCall(token common.Address, to common.Address, amount *big.Int, data []byte, gasLimit *big.Int) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.WithdrawERC20AndCall(&_IL2GatewayRouter.TransactOpts, token, to, amount, data, gasLimit) } // WithdrawERC20AndCall is a paid mutator transaction binding the contract method 0x575361b6. // // Solidity: function withdrawERC20AndCall(address token, address to, uint256 amount, bytes data, uint256 gasLimit) payable returns() func (_IL2GatewayRouter *IL2GatewayRouterTransactorSession) WithdrawERC20AndCall(token common.Address, to common.Address, amount *big.Int, data []byte, gasLimit *big.Int) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.WithdrawERC20AndCall(&_IL2GatewayRouter.TransactOpts, token, to, amount, data, gasLimit) } // WithdrawETH is a paid mutator transaction binding the contract method 0x2fcc29fa. // // Solidity: function withdrawETH(address to, uint256 amount, uint256 gasLimit) payable returns() func (_IL2GatewayRouter *IL2GatewayRouterTransactor) WithdrawETH(opts *bind.TransactOpts, to common.Address, amount *big.Int, gasLimit *big.Int) (*types.Transaction, error) { return _IL2GatewayRouter.contract.Transact(opts, "withdrawETH", to, amount, gasLimit) } // WithdrawETH is a paid mutator transaction binding the contract method 0x2fcc29fa. // // Solidity: function withdrawETH(address to, uint256 amount, uint256 gasLimit) payable returns() func (_IL2GatewayRouter *IL2GatewayRouterSession) WithdrawETH(to common.Address, amount *big.Int, gasLimit *big.Int) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.WithdrawETH(&_IL2GatewayRouter.TransactOpts, to, amount, gasLimit) } // WithdrawETH is a paid mutator transaction binding the contract method 0x2fcc29fa. // // Solidity: function withdrawETH(address to, uint256 amount, uint256 gasLimit) payable returns() func (_IL2GatewayRouter *IL2GatewayRouterTransactorSession) WithdrawETH(to common.Address, amount *big.Int, gasLimit *big.Int) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.WithdrawETH(&_IL2GatewayRouter.TransactOpts, to, amount, gasLimit) } // WithdrawETH0 is a paid mutator transaction binding the contract method 0xc7cdea37. // // Solidity: function withdrawETH(uint256 amount, uint256 gasLimit) payable returns() func (_IL2GatewayRouter *IL2GatewayRouterTransactor) WithdrawETH0(opts *bind.TransactOpts, amount *big.Int, gasLimit *big.Int) (*types.Transaction, error) { return _IL2GatewayRouter.contract.Transact(opts, "withdrawETH0", amount, gasLimit) } // WithdrawETH0 is a paid mutator transaction binding the contract method 0xc7cdea37. // // Solidity: function withdrawETH(uint256 amount, uint256 gasLimit) payable returns() func (_IL2GatewayRouter *IL2GatewayRouterSession) WithdrawETH0(amount *big.Int, gasLimit *big.Int) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.WithdrawETH0(&_IL2GatewayRouter.TransactOpts, amount, gasLimit) } // WithdrawETH0 is a paid mutator transaction binding the contract method 0xc7cdea37. // // Solidity: function withdrawETH(uint256 amount, uint256 gasLimit) payable returns() func (_IL2GatewayRouter *IL2GatewayRouterTransactorSession) WithdrawETH0(amount *big.Int, gasLimit *big.Int) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.WithdrawETH0(&_IL2GatewayRouter.TransactOpts, amount, gasLimit) } // WithdrawETHAndCall is a paid mutator transaction binding the contract method 0x6dc24183. // // Solidity: function withdrawETHAndCall(address to, uint256 amount, bytes data, uint256 gasLimit) payable returns() func (_IL2GatewayRouter *IL2GatewayRouterTransactor) WithdrawETHAndCall(opts *bind.TransactOpts, to common.Address, amount *big.Int, data []byte, gasLimit *big.Int) (*types.Transaction, error) { return _IL2GatewayRouter.contract.Transact(opts, "withdrawETHAndCall", to, amount, data, gasLimit) } // WithdrawETHAndCall is a paid mutator transaction binding the contract method 0x6dc24183. // // Solidity: function withdrawETHAndCall(address to, uint256 amount, bytes data, uint256 gasLimit) payable returns() func (_IL2GatewayRouter *IL2GatewayRouterSession) WithdrawETHAndCall(to common.Address, amount *big.Int, data []byte, gasLimit *big.Int) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.WithdrawETHAndCall(&_IL2GatewayRouter.TransactOpts, to, amount, data, gasLimit) } // WithdrawETHAndCall is a paid mutator transaction binding the contract method 0x6dc24183. // // Solidity: function withdrawETHAndCall(address to, uint256 amount, bytes data, uint256 gasLimit) payable returns() func (_IL2GatewayRouter *IL2GatewayRouterTransactorSession) WithdrawETHAndCall(to common.Address, amount *big.Int, data []byte, gasLimit *big.Int) (*types.Transaction, error) { return _IL2GatewayRouter.Contract.WithdrawETHAndCall(&_IL2GatewayRouter.TransactOpts, to, amount, data, gasLimit) } // IL2GatewayRouterFinalizeDepositERC20Iterator is returned from FilterFinalizeDepositERC20 and is used to iterate over the raw logs and unpacked data for FinalizeDepositERC20 events raised by the IL2GatewayRouter contract. type IL2GatewayRouterFinalizeDepositERC20Iterator struct { Event *IL2GatewayRouterFinalizeDepositERC20 // 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 *IL2GatewayRouterFinalizeDepositERC20Iterator) 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(IL2GatewayRouterFinalizeDepositERC20) 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(IL2GatewayRouterFinalizeDepositERC20) 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 *IL2GatewayRouterFinalizeDepositERC20Iterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. func (it *IL2GatewayRouterFinalizeDepositERC20Iterator) Close() error { it.sub.Unsubscribe() return nil } // IL2GatewayRouterFinalizeDepositERC20 represents a FinalizeDepositERC20 event raised by the IL2GatewayRouter contract. type IL2GatewayRouterFinalizeDepositERC20 struct { L1Token common.Address L2Token common.Address From common.Address To common.Address Amount *big.Int Data []byte Raw types.Log // Blockchain specific contextual infos } // FilterFinalizeDepositERC20 is a free log retrieval operation binding the contract event 0x165ba69f6ab40c50cade6f65431801e5f9c7d7830b7545391920db039133ba34. // // Solidity: event FinalizeDepositERC20(address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data) func (_IL2GatewayRouter *IL2GatewayRouterFilterer) FilterFinalizeDepositERC20(opts *bind.FilterOpts, l1Token []common.Address, l2Token []common.Address, from []common.Address) (*IL2GatewayRouterFinalizeDepositERC20Iterator, error) { var l1TokenRule []interface{} for _, l1TokenItem := range l1Token { l1TokenRule = append(l1TokenRule, l1TokenItem) } var l2TokenRule []interface{} for _, l2TokenItem := range l2Token { l2TokenRule = append(l2TokenRule, l2TokenItem) } var fromRule []interface{} for _, fromItem := range from { fromRule = append(fromRule, fromItem) } logs, sub, err := _IL2GatewayRouter.contract.FilterLogs(opts, "FinalizeDepositERC20", l1TokenRule, l2TokenRule, fromRule) if err != nil { return nil, err } return &IL2GatewayRouterFinalizeDepositERC20Iterator{contract: _IL2GatewayRouter.contract, event: "FinalizeDepositERC20", logs: logs, sub: sub}, nil } // WatchFinalizeDepositERC20 is a free log subscription operation binding the contract event 0x165ba69f6ab40c50cade6f65431801e5f9c7d7830b7545391920db039133ba34. // // Solidity: event FinalizeDepositERC20(address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data) func (_IL2GatewayRouter *IL2GatewayRouterFilterer) WatchFinalizeDepositERC20(opts *bind.WatchOpts, sink chan<- *IL2GatewayRouterFinalizeDepositERC20, l1Token []common.Address, l2Token []common.Address, from []common.Address) (event.Subscription, error) { var l1TokenRule []interface{} for _, l1TokenItem := range l1Token { l1TokenRule = append(l1TokenRule, l1TokenItem) } var l2TokenRule []interface{} for _, l2TokenItem := range l2Token { l2TokenRule = append(l2TokenRule, l2TokenItem) } var fromRule []interface{} for _, fromItem := range from { fromRule = append(fromRule, fromItem) } logs, sub, err := _IL2GatewayRouter.contract.WatchLogs(opts, "FinalizeDepositERC20", l1TokenRule, l2TokenRule, fromRule) 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(IL2GatewayRouterFinalizeDepositERC20) if err := _IL2GatewayRouter.contract.UnpackLog(event, "FinalizeDepositERC20", 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 } // ParseFinalizeDepositERC20 is a log parse operation binding the contract event 0x165ba69f6ab40c50cade6f65431801e5f9c7d7830b7545391920db039133ba34. // // Solidity: event FinalizeDepositERC20(address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data) func (_IL2GatewayRouter *IL2GatewayRouterFilterer) ParseFinalizeDepositERC20(log types.Log) (*IL2GatewayRouterFinalizeDepositERC20, error) { event := new(IL2GatewayRouterFinalizeDepositERC20) if err := _IL2GatewayRouter.contract.UnpackLog(event, "FinalizeDepositERC20", log); err != nil { return nil, err } event.Raw = log return event, nil } // IL2GatewayRouterFinalizeDepositETHIterator is returned from FilterFinalizeDepositETH and is used to iterate over the raw logs and unpacked data for FinalizeDepositETH events raised by the IL2GatewayRouter contract. type IL2GatewayRouterFinalizeDepositETHIterator struct { Event *IL2GatewayRouterFinalizeDepositETH // 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 *IL2GatewayRouterFinalizeDepositETHIterator) 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(IL2GatewayRouterFinalizeDepositETH) 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(IL2GatewayRouterFinalizeDepositETH) 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 *IL2GatewayRouterFinalizeDepositETHIterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. func (it *IL2GatewayRouterFinalizeDepositETHIterator) Close() error { it.sub.Unsubscribe() return nil } // IL2GatewayRouterFinalizeDepositETH represents a FinalizeDepositETH event raised by the IL2GatewayRouter contract. type IL2GatewayRouterFinalizeDepositETH struct { From common.Address To common.Address Amount *big.Int Data []byte Raw types.Log // Blockchain specific contextual infos } // FilterFinalizeDepositETH is a free log retrieval operation binding the contract event 0x9e86c356e14e24e26e3ce769bf8b87de38e0faa0ed0ca946fa09659aa606bd2d. // // Solidity: event FinalizeDepositETH(address indexed from, address indexed to, uint256 amount, bytes data) func (_IL2GatewayRouter *IL2GatewayRouterFilterer) FilterFinalizeDepositETH(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*IL2GatewayRouterFinalizeDepositETHIterator, error) { var fromRule []interface{} for _, fromItem := range from { fromRule = append(fromRule, fromItem) } var toRule []interface{} for _, toItem := range to { toRule = append(toRule, toItem) } logs, sub, err := _IL2GatewayRouter.contract.FilterLogs(opts, "FinalizeDepositETH", fromRule, toRule) if err != nil { return nil, err } return &IL2GatewayRouterFinalizeDepositETHIterator{contract: _IL2GatewayRouter.contract, event: "FinalizeDepositETH", logs: logs, sub: sub}, nil } // WatchFinalizeDepositETH is a free log subscription operation binding the contract event 0x9e86c356e14e24e26e3ce769bf8b87de38e0faa0ed0ca946fa09659aa606bd2d. // // Solidity: event FinalizeDepositETH(address indexed from, address indexed to, uint256 amount, bytes data) func (_IL2GatewayRouter *IL2GatewayRouterFilterer) WatchFinalizeDepositETH(opts *bind.WatchOpts, sink chan<- *IL2GatewayRouterFinalizeDepositETH, from []common.Address, to []common.Address) (event.Subscription, error) { var fromRule []interface{} for _, fromItem := range from { fromRule = append(fromRule, fromItem) } var toRule []interface{} for _, toItem := range to { toRule = append(toRule, toItem) } logs, sub, err := _IL2GatewayRouter.contract.WatchLogs(opts, "FinalizeDepositETH", fromRule, toRule) 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(IL2GatewayRouterFinalizeDepositETH) if err := _IL2GatewayRouter.contract.UnpackLog(event, "FinalizeDepositETH", 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 } // ParseFinalizeDepositETH is a log parse operation binding the contract event 0x9e86c356e14e24e26e3ce769bf8b87de38e0faa0ed0ca946fa09659aa606bd2d. // // Solidity: event FinalizeDepositETH(address indexed from, address indexed to, uint256 amount, bytes data) func (_IL2GatewayRouter *IL2GatewayRouterFilterer) ParseFinalizeDepositETH(log types.Log) (*IL2GatewayRouterFinalizeDepositETH, error) { event := new(IL2GatewayRouterFinalizeDepositETH) if err := _IL2GatewayRouter.contract.UnpackLog(event, "FinalizeDepositETH", log); err != nil { return nil, err } event.Raw = log return event, nil } // IL2GatewayRouterSetDefaultERC20GatewayIterator is returned from FilterSetDefaultERC20Gateway and is used to iterate over the raw logs and unpacked data for SetDefaultERC20Gateway events raised by the IL2GatewayRouter contract. type IL2GatewayRouterSetDefaultERC20GatewayIterator struct { Event *IL2GatewayRouterSetDefaultERC20Gateway // 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 *IL2GatewayRouterSetDefaultERC20GatewayIterator) 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(IL2GatewayRouterSetDefaultERC20Gateway) 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(IL2GatewayRouterSetDefaultERC20Gateway) 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 *IL2GatewayRouterSetDefaultERC20GatewayIterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. func (it *IL2GatewayRouterSetDefaultERC20GatewayIterator) Close() error { it.sub.Unsubscribe() return nil } // IL2GatewayRouterSetDefaultERC20Gateway represents a SetDefaultERC20Gateway event raised by the IL2GatewayRouter contract. type IL2GatewayRouterSetDefaultERC20Gateway struct { OldDefaultERC20Gateway common.Address NewDefaultERC20Gateway common.Address Raw types.Log // Blockchain specific contextual infos } // FilterSetDefaultERC20Gateway is a free log retrieval operation binding the contract event 0x2904fcae71038f87b116fd2875871e153722cabddd71de1b77473de263cd74d1. // // Solidity: event SetDefaultERC20Gateway(address indexed oldDefaultERC20Gateway, address indexed newDefaultERC20Gateway) func (_IL2GatewayRouter *IL2GatewayRouterFilterer) FilterSetDefaultERC20Gateway(opts *bind.FilterOpts, oldDefaultERC20Gateway []common.Address, newDefaultERC20Gateway []common.Address) (*IL2GatewayRouterSetDefaultERC20GatewayIterator, error) { var oldDefaultERC20GatewayRule []interface{} for _, oldDefaultERC20GatewayItem := range oldDefaultERC20Gateway { oldDefaultERC20GatewayRule = append(oldDefaultERC20GatewayRule, oldDefaultERC20GatewayItem) } var newDefaultERC20GatewayRule []interface{} for _, newDefaultERC20GatewayItem := range newDefaultERC20Gateway { newDefaultERC20GatewayRule = append(newDefaultERC20GatewayRule, newDefaultERC20GatewayItem) } logs, sub, err := _IL2GatewayRouter.contract.FilterLogs(opts, "SetDefaultERC20Gateway", oldDefaultERC20GatewayRule, newDefaultERC20GatewayRule) if err != nil { return nil, err } return &IL2GatewayRouterSetDefaultERC20GatewayIterator{contract: _IL2GatewayRouter.contract, event: "SetDefaultERC20Gateway", logs: logs, sub: sub}, nil } // WatchSetDefaultERC20Gateway is a free log subscription operation binding the contract event 0x2904fcae71038f87b116fd2875871e153722cabddd71de1b77473de263cd74d1. // // Solidity: event SetDefaultERC20Gateway(address indexed oldDefaultERC20Gateway, address indexed newDefaultERC20Gateway) func (_IL2GatewayRouter *IL2GatewayRouterFilterer) WatchSetDefaultERC20Gateway(opts *bind.WatchOpts, sink chan<- *IL2GatewayRouterSetDefaultERC20Gateway, oldDefaultERC20Gateway []common.Address, newDefaultERC20Gateway []common.Address) (event.Subscription, error) { var oldDefaultERC20GatewayRule []interface{} for _, oldDefaultERC20GatewayItem := range oldDefaultERC20Gateway { oldDefaultERC20GatewayRule = append(oldDefaultERC20GatewayRule, oldDefaultERC20GatewayItem) } var newDefaultERC20GatewayRule []interface{} for _, newDefaultERC20GatewayItem := range newDefaultERC20Gateway { newDefaultERC20GatewayRule = append(newDefaultERC20GatewayRule, newDefaultERC20GatewayItem) } logs, sub, err := _IL2GatewayRouter.contract.WatchLogs(opts, "SetDefaultERC20Gateway", oldDefaultERC20GatewayRule, newDefaultERC20GatewayRule) 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(IL2GatewayRouterSetDefaultERC20Gateway) if err := _IL2GatewayRouter.contract.UnpackLog(event, "SetDefaultERC20Gateway", 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 } // ParseSetDefaultERC20Gateway is a log parse operation binding the contract event 0x2904fcae71038f87b116fd2875871e153722cabddd71de1b77473de263cd74d1. // // Solidity: event SetDefaultERC20Gateway(address indexed oldDefaultERC20Gateway, address indexed newDefaultERC20Gateway) func (_IL2GatewayRouter *IL2GatewayRouterFilterer) ParseSetDefaultERC20Gateway(log types.Log) (*IL2GatewayRouterSetDefaultERC20Gateway, error) { event := new(IL2GatewayRouterSetDefaultERC20Gateway) if err := _IL2GatewayRouter.contract.UnpackLog(event, "SetDefaultERC20Gateway", log); err != nil { return nil, err } event.Raw = log return event, nil } // IL2GatewayRouterSetERC20GatewayIterator is returned from FilterSetERC20Gateway and is used to iterate over the raw logs and unpacked data for SetERC20Gateway events raised by the IL2GatewayRouter contract. type IL2GatewayRouterSetERC20GatewayIterator struct { Event *IL2GatewayRouterSetERC20Gateway // 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 *IL2GatewayRouterSetERC20GatewayIterator) 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(IL2GatewayRouterSetERC20Gateway) 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(IL2GatewayRouterSetERC20Gateway) 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 *IL2GatewayRouterSetERC20GatewayIterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. func (it *IL2GatewayRouterSetERC20GatewayIterator) Close() error { it.sub.Unsubscribe() return nil } // IL2GatewayRouterSetERC20Gateway represents a SetERC20Gateway event raised by the IL2GatewayRouter contract. type IL2GatewayRouterSetERC20Gateway struct { Token common.Address OldGateway common.Address NewGateway common.Address Raw types.Log // Blockchain specific contextual infos } // FilterSetERC20Gateway is a free log retrieval operation binding the contract event 0x0ead4808404683f66d413d788a768219ea9785c97889221193103841a5841eaf. // // Solidity: event SetERC20Gateway(address indexed token, address indexed oldGateway, address indexed newGateway) func (_IL2GatewayRouter *IL2GatewayRouterFilterer) FilterSetERC20Gateway(opts *bind.FilterOpts, token []common.Address, oldGateway []common.Address, newGateway []common.Address) (*IL2GatewayRouterSetERC20GatewayIterator, error) { var tokenRule []interface{} for _, tokenItem := range token { tokenRule = append(tokenRule, tokenItem) } var oldGatewayRule []interface{} for _, oldGatewayItem := range oldGateway { oldGatewayRule = append(oldGatewayRule, oldGatewayItem) } var newGatewayRule []interface{} for _, newGatewayItem := range newGateway { newGatewayRule = append(newGatewayRule, newGatewayItem) } logs, sub, err := _IL2GatewayRouter.contract.FilterLogs(opts, "SetERC20Gateway", tokenRule, oldGatewayRule, newGatewayRule) if err != nil { return nil, err } return &IL2GatewayRouterSetERC20GatewayIterator{contract: _IL2GatewayRouter.contract, event: "SetERC20Gateway", logs: logs, sub: sub}, nil } // WatchSetERC20Gateway is a free log subscription operation binding the contract event 0x0ead4808404683f66d413d788a768219ea9785c97889221193103841a5841eaf. // // Solidity: event SetERC20Gateway(address indexed token, address indexed oldGateway, address indexed newGateway) func (_IL2GatewayRouter *IL2GatewayRouterFilterer) WatchSetERC20Gateway(opts *bind.WatchOpts, sink chan<- *IL2GatewayRouterSetERC20Gateway, token []common.Address, oldGateway []common.Address, newGateway []common.Address) (event.Subscription, error) { var tokenRule []interface{} for _, tokenItem := range token { tokenRule = append(tokenRule, tokenItem) } var oldGatewayRule []interface{} for _, oldGatewayItem := range oldGateway { oldGatewayRule = append(oldGatewayRule, oldGatewayItem) } var newGatewayRule []interface{} for _, newGatewayItem := range newGateway { newGatewayRule = append(newGatewayRule, newGatewayItem) } logs, sub, err := _IL2GatewayRouter.contract.WatchLogs(opts, "SetERC20Gateway", tokenRule, oldGatewayRule, newGatewayRule) 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(IL2GatewayRouterSetERC20Gateway) if err := _IL2GatewayRouter.contract.UnpackLog(event, "SetERC20Gateway", 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 } // ParseSetERC20Gateway is a log parse operation binding the contract event 0x0ead4808404683f66d413d788a768219ea9785c97889221193103841a5841eaf. // // Solidity: event SetERC20Gateway(address indexed token, address indexed oldGateway, address indexed newGateway) func (_IL2GatewayRouter *IL2GatewayRouterFilterer) ParseSetERC20Gateway(log types.Log) (*IL2GatewayRouterSetERC20Gateway, error) { event := new(IL2GatewayRouterSetERC20Gateway) if err := _IL2GatewayRouter.contract.UnpackLog(event, "SetERC20Gateway", log); err != nil { return nil, err } event.Raw = log return event, nil } // IL2GatewayRouterSetETHGatewayIterator is returned from FilterSetETHGateway and is used to iterate over the raw logs and unpacked data for SetETHGateway events raised by the IL2GatewayRouter contract. type IL2GatewayRouterSetETHGatewayIterator struct { Event *IL2GatewayRouterSetETHGateway // 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 *IL2GatewayRouterSetETHGatewayIterator) 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(IL2GatewayRouterSetETHGateway) 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(IL2GatewayRouterSetETHGateway) 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 *IL2GatewayRouterSetETHGatewayIterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. func (it *IL2GatewayRouterSetETHGatewayIterator) Close() error { it.sub.Unsubscribe() return nil } // IL2GatewayRouterSetETHGateway represents a SetETHGateway event raised by the IL2GatewayRouter contract. type IL2GatewayRouterSetETHGateway struct { OldETHGateway common.Address NewEthGateway common.Address Raw types.Log // Blockchain specific contextual infos } // FilterSetETHGateway is a free log retrieval operation binding the contract event 0xa1bfcc6dd729ad197a1180f44d5c12bcc630943df0874b9ed53da23165621b6a. // // Solidity: event SetETHGateway(address indexed oldETHGateway, address indexed newEthGateway) func (_IL2GatewayRouter *IL2GatewayRouterFilterer) FilterSetETHGateway(opts *bind.FilterOpts, oldETHGateway []common.Address, newEthGateway []common.Address) (*IL2GatewayRouterSetETHGatewayIterator, error) { var oldETHGatewayRule []interface{} for _, oldETHGatewayItem := range oldETHGateway { oldETHGatewayRule = append(oldETHGatewayRule, oldETHGatewayItem) } var newEthGatewayRule []interface{} for _, newEthGatewayItem := range newEthGateway { newEthGatewayRule = append(newEthGatewayRule, newEthGatewayItem) } logs, sub, err := _IL2GatewayRouter.contract.FilterLogs(opts, "SetETHGateway", oldETHGatewayRule, newEthGatewayRule) if err != nil { return nil, err } return &IL2GatewayRouterSetETHGatewayIterator{contract: _IL2GatewayRouter.contract, event: "SetETHGateway", logs: logs, sub: sub}, nil } // WatchSetETHGateway is a free log subscription operation binding the contract event 0xa1bfcc6dd729ad197a1180f44d5c12bcc630943df0874b9ed53da23165621b6a. // // Solidity: event SetETHGateway(address indexed oldETHGateway, address indexed newEthGateway) func (_IL2GatewayRouter *IL2GatewayRouterFilterer) WatchSetETHGateway(opts *bind.WatchOpts, sink chan<- *IL2GatewayRouterSetETHGateway, oldETHGateway []common.Address, newEthGateway []common.Address) (event.Subscription, error) { var oldETHGatewayRule []interface{} for _, oldETHGatewayItem := range oldETHGateway { oldETHGatewayRule = append(oldETHGatewayRule, oldETHGatewayItem) } var newEthGatewayRule []interface{} for _, newEthGatewayItem := range newEthGateway { newEthGatewayRule = append(newEthGatewayRule, newEthGatewayItem) } logs, sub, err := _IL2GatewayRouter.contract.WatchLogs(opts, "SetETHGateway", oldETHGatewayRule, newEthGatewayRule) 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(IL2GatewayRouterSetETHGateway) if err := _IL2GatewayRouter.contract.UnpackLog(event, "SetETHGateway", 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 } // ParseSetETHGateway is a log parse operation binding the contract event 0xa1bfcc6dd729ad197a1180f44d5c12bcc630943df0874b9ed53da23165621b6a. // // Solidity: event SetETHGateway(address indexed oldETHGateway, address indexed newEthGateway) func (_IL2GatewayRouter *IL2GatewayRouterFilterer) ParseSetETHGateway(log types.Log) (*IL2GatewayRouterSetETHGateway, error) { event := new(IL2GatewayRouterSetETHGateway) if err := _IL2GatewayRouter.contract.UnpackLog(event, "SetETHGateway", log); err != nil { return nil, err } event.Raw = log return event, nil } // IL2GatewayRouterWithdrawERC20Iterator is returned from FilterWithdrawERC20 and is used to iterate over the raw logs and unpacked data for WithdrawERC20 events raised by the IL2GatewayRouter contract. type IL2GatewayRouterWithdrawERC20Iterator struct { Event *IL2GatewayRouterWithdrawERC20 // 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 *IL2GatewayRouterWithdrawERC20Iterator) 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(IL2GatewayRouterWithdrawERC20) 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(IL2GatewayRouterWithdrawERC20) 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 *IL2GatewayRouterWithdrawERC20Iterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. func (it *IL2GatewayRouterWithdrawERC20Iterator) Close() error { it.sub.Unsubscribe() return nil } // IL2GatewayRouterWithdrawERC20 represents a WithdrawERC20 event raised by the IL2GatewayRouter contract. type IL2GatewayRouterWithdrawERC20 struct { L1Token common.Address L2Token common.Address From common.Address To common.Address Amount *big.Int Data []byte Raw types.Log // Blockchain specific contextual infos } // FilterWithdrawERC20 is a free log retrieval operation binding the contract event 0xd8d3a3f4ab95694bef40475997598bcf8acd3ed9617a4c1013795429414c27e8. // // Solidity: event WithdrawERC20(address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data) func (_IL2GatewayRouter *IL2GatewayRouterFilterer) FilterWithdrawERC20(opts *bind.FilterOpts, l1Token []common.Address, l2Token []common.Address, from []common.Address) (*IL2GatewayRouterWithdrawERC20Iterator, error) { var l1TokenRule []interface{} for _, l1TokenItem := range l1Token { l1TokenRule = append(l1TokenRule, l1TokenItem) } var l2TokenRule []interface{} for _, l2TokenItem := range l2Token { l2TokenRule = append(l2TokenRule, l2TokenItem) } var fromRule []interface{} for _, fromItem := range from { fromRule = append(fromRule, fromItem) } logs, sub, err := _IL2GatewayRouter.contract.FilterLogs(opts, "WithdrawERC20", l1TokenRule, l2TokenRule, fromRule) if err != nil { return nil, err } return &IL2GatewayRouterWithdrawERC20Iterator{contract: _IL2GatewayRouter.contract, event: "WithdrawERC20", logs: logs, sub: sub}, nil } // WatchWithdrawERC20 is a free log subscription operation binding the contract event 0xd8d3a3f4ab95694bef40475997598bcf8acd3ed9617a4c1013795429414c27e8. // // Solidity: event WithdrawERC20(address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data) func (_IL2GatewayRouter *IL2GatewayRouterFilterer) WatchWithdrawERC20(opts *bind.WatchOpts, sink chan<- *IL2GatewayRouterWithdrawERC20, l1Token []common.Address, l2Token []common.Address, from []common.Address) (event.Subscription, error) { var l1TokenRule []interface{} for _, l1TokenItem := range l1Token { l1TokenRule = append(l1TokenRule, l1TokenItem) } var l2TokenRule []interface{} for _, l2TokenItem := range l2Token { l2TokenRule = append(l2TokenRule, l2TokenItem) } var fromRule []interface{} for _, fromItem := range from { fromRule = append(fromRule, fromItem) } logs, sub, err := _IL2GatewayRouter.contract.WatchLogs(opts, "WithdrawERC20", l1TokenRule, l2TokenRule, fromRule) 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(IL2GatewayRouterWithdrawERC20) if err := _IL2GatewayRouter.contract.UnpackLog(event, "WithdrawERC20", 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 } // ParseWithdrawERC20 is a log parse operation binding the contract event 0xd8d3a3f4ab95694bef40475997598bcf8acd3ed9617a4c1013795429414c27e8. // // Solidity: event WithdrawERC20(address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data) func (_IL2GatewayRouter *IL2GatewayRouterFilterer) ParseWithdrawERC20(log types.Log) (*IL2GatewayRouterWithdrawERC20, error) { event := new(IL2GatewayRouterWithdrawERC20) if err := _IL2GatewayRouter.contract.UnpackLog(event, "WithdrawERC20", log); err != nil { return nil, err } event.Raw = log return event, nil } // IL2GatewayRouterWithdrawETHIterator is returned from FilterWithdrawETH and is used to iterate over the raw logs and unpacked data for WithdrawETH events raised by the IL2GatewayRouter contract. type IL2GatewayRouterWithdrawETHIterator struct { Event *IL2GatewayRouterWithdrawETH // 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 *IL2GatewayRouterWithdrawETHIterator) 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(IL2GatewayRouterWithdrawETH) 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(IL2GatewayRouterWithdrawETH) 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 *IL2GatewayRouterWithdrawETHIterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. func (it *IL2GatewayRouterWithdrawETHIterator) Close() error { it.sub.Unsubscribe() return nil } // IL2GatewayRouterWithdrawETH represents a WithdrawETH event raised by the IL2GatewayRouter contract. type IL2GatewayRouterWithdrawETH struct { From common.Address To common.Address Amount *big.Int Data []byte Raw types.Log // Blockchain specific contextual infos } // FilterWithdrawETH is a free log retrieval operation binding the contract event 0xd8ed6eaa9a7a8980d7901e911fde6686810b989d3082182d1d3a3df6306ce20e. // // Solidity: event WithdrawETH(address indexed from, address indexed to, uint256 amount, bytes data) func (_IL2GatewayRouter *IL2GatewayRouterFilterer) FilterWithdrawETH(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*IL2GatewayRouterWithdrawETHIterator, error) { var fromRule []interface{} for _, fromItem := range from { fromRule = append(fromRule, fromItem) } var toRule []interface{} for _, toItem := range to { toRule = append(toRule, toItem) } logs, sub, err := _IL2GatewayRouter.contract.FilterLogs(opts, "WithdrawETH", fromRule, toRule) if err != nil { return nil, err } return &IL2GatewayRouterWithdrawETHIterator{contract: _IL2GatewayRouter.contract, event: "WithdrawETH", logs: logs, sub: sub}, nil } // WatchWithdrawETH is a free log subscription operation binding the contract event 0xd8ed6eaa9a7a8980d7901e911fde6686810b989d3082182d1d3a3df6306ce20e. // // Solidity: event WithdrawETH(address indexed from, address indexed to, uint256 amount, bytes data) func (_IL2GatewayRouter *IL2GatewayRouterFilterer) WatchWithdrawETH(opts *bind.WatchOpts, sink chan<- *IL2GatewayRouterWithdrawETH, from []common.Address, to []common.Address) (event.Subscription, error) { var fromRule []interface{} for _, fromItem := range from { fromRule = append(fromRule, fromItem) } var toRule []interface{} for _, toItem := range to { toRule = append(toRule, toItem) } logs, sub, err := _IL2GatewayRouter.contract.WatchLogs(opts, "WithdrawETH", fromRule, toRule) 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(IL2GatewayRouterWithdrawETH) if err := _IL2GatewayRouter.contract.UnpackLog(event, "WithdrawETH", 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 } // ParseWithdrawETH is a log parse operation binding the contract event 0xd8ed6eaa9a7a8980d7901e911fde6686810b989d3082182d1d3a3df6306ce20e. // // Solidity: event WithdrawETH(address indexed from, address indexed to, uint256 amount, bytes data) func (_IL2GatewayRouter *IL2GatewayRouterFilterer) ParseWithdrawETH(log types.Log) (*IL2GatewayRouterWithdrawETH, error) { event := new(IL2GatewayRouterWithdrawETH) if err := _IL2GatewayRouter.contract.UnpackLog(event, "WithdrawETH", log); err != nil { return nil, err } event.Raw = log return event, nil } // InitializableMetaData contains all meta data concerning the Initializable contract. var InitializableMetaData = &bind.MetaData{ ABI: "[{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"name\":\"Initialized\",\"type\":\"event\"}]", } // InitializableABI is the input ABI used to generate the binding from. // Deprecated: Use InitializableMetaData.ABI instead. var InitializableABI = InitializableMetaData.ABI // Initializable is an auto generated Go binding around an Ethereum contract. type Initializable struct { InitializableCaller // Read-only binding to the contract InitializableTransactor // Write-only binding to the contract InitializableFilterer // Log filterer for contract events } // InitializableCaller is an auto generated read-only Go binding around an Ethereum contract. type InitializableCaller struct { contract *bind.BoundContract // Generic contract wrapper for the low level calls } // InitializableTransactor is an auto generated write-only Go binding around an Ethereum contract. type InitializableTransactor struct { contract *bind.BoundContract // Generic contract wrapper for the low level calls } // InitializableFilterer is an auto generated log filtering Go binding around an Ethereum contract events. type InitializableFilterer struct { contract *bind.BoundContract // Generic contract wrapper for the low level calls } // InitializableSession is an auto generated Go binding around an Ethereum contract, // with pre-set call and transact options. type InitializableSession struct { Contract *Initializable // 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 } // InitializableCallerSession is an auto generated read-only Go binding around an Ethereum contract, // with pre-set call options. type InitializableCallerSession struct { Contract *InitializableCaller // Generic contract caller binding to set the session for CallOpts bind.CallOpts // Call options to use throughout this session } // InitializableTransactorSession is an auto generated write-only Go binding around an Ethereum contract, // with pre-set transact options. type InitializableTransactorSession struct { Contract *InitializableTransactor // Generic contract transactor binding to set the session for TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session } // InitializableRaw is an auto generated low-level Go binding around an Ethereum contract. type InitializableRaw struct { Contract *Initializable // Generic contract binding to access the raw methods on } // InitializableCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract. type InitializableCallerRaw struct { Contract *InitializableCaller // Generic read-only contract binding to access the raw methods on } // InitializableTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract. type InitializableTransactorRaw struct { Contract *InitializableTransactor // Generic write-only contract binding to access the raw methods on } // NewInitializable creates a new instance of Initializable, bound to a specific deployed contract. func NewInitializable(address common.Address, backend bind.ContractBackend) (*Initializable, error) { contract, err := bindInitializable(address, backend, backend, backend) if err != nil { return nil, err } return &Initializable{InitializableCaller: InitializableCaller{contract: contract}, InitializableTransactor: InitializableTransactor{contract: contract}, InitializableFilterer: InitializableFilterer{contract: contract}}, nil } // NewInitializableCaller creates a new read-only instance of Initializable, bound to a specific deployed contract. func NewInitializableCaller(address common.Address, caller bind.ContractCaller) (*InitializableCaller, error) { contract, err := bindInitializable(address, caller, nil, nil) if err != nil { return nil, err } return &InitializableCaller{contract: contract}, nil } // NewInitializableTransactor creates a new write-only instance of Initializable, bound to a specific deployed contract. func NewInitializableTransactor(address common.Address, transactor bind.ContractTransactor) (*InitializableTransactor, error) { contract, err := bindInitializable(address, nil, transactor, nil) if err != nil { return nil, err } return &InitializableTransactor{contract: contract}, nil } // NewInitializableFilterer creates a new log filterer instance of Initializable, bound to a specific deployed contract. func NewInitializableFilterer(address common.Address, filterer bind.ContractFilterer) (*InitializableFilterer, error) { contract, err := bindInitializable(address, nil, nil, filterer) if err != nil { return nil, err } return &InitializableFilterer{contract: contract}, nil } // bindInitializable binds a generic wrapper to an already deployed contract. func bindInitializable(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { parsed, err := InitializableMetaData.GetAbi() 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 (_Initializable *InitializableRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { return _Initializable.Contract.InitializableCaller.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 (_Initializable *InitializableRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { return _Initializable.Contract.InitializableTransactor.contract.Transfer(opts) } // Transact invokes the (paid) contract method with params as input values. func (_Initializable *InitializableRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { return _Initializable.Contract.InitializableTransactor.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 (_Initializable *InitializableCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { return _Initializable.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 (_Initializable *InitializableTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { return _Initializable.Contract.contract.Transfer(opts) } // Transact invokes the (paid) contract method with params as input values. func (_Initializable *InitializableTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { return _Initializable.Contract.contract.Transact(opts, method, params...) } // InitializableInitializedIterator is returned from FilterInitialized and is used to iterate over the raw logs and unpacked data for Initialized events raised by the Initializable contract. type InitializableInitializedIterator struct { Event *InitializableInitialized // 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 *InitializableInitializedIterator) 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(InitializableInitialized) 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(InitializableInitialized) 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 *InitializableInitializedIterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. func (it *InitializableInitializedIterator) Close() error { it.sub.Unsubscribe() return nil } // InitializableInitialized represents a Initialized event raised by the Initializable contract. type InitializableInitialized struct { Version uint8 Raw types.Log // Blockchain specific contextual infos } // FilterInitialized is a free log retrieval operation binding the contract event 0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498. // // Solidity: event Initialized(uint8 version) func (_Initializable *InitializableFilterer) FilterInitialized(opts *bind.FilterOpts) (*InitializableInitializedIterator, error) { logs, sub, err := _Initializable.contract.FilterLogs(opts, "Initialized") if err != nil { return nil, err } return &InitializableInitializedIterator{contract: _Initializable.contract, event: "Initialized", logs: logs, sub: sub}, nil } // WatchInitialized is a free log subscription operation binding the contract event 0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498. // // Solidity: event Initialized(uint8 version) func (_Initializable *InitializableFilterer) WatchInitialized(opts *bind.WatchOpts, sink chan<- *InitializableInitialized) (event.Subscription, error) { logs, sub, err := _Initializable.contract.WatchLogs(opts, "Initialized") 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(InitializableInitialized) if err := _Initializable.contract.UnpackLog(event, "Initialized", 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 } // ParseInitialized is a log parse operation binding the contract event 0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498. // // Solidity: event Initialized(uint8 version) func (_Initializable *InitializableFilterer) ParseInitialized(log types.Log) (*InitializableInitialized, error) { event := new(InitializableInitialized) if err := _Initializable.contract.UnpackLog(event, "Initialized", log); err != nil { return nil, err } event.Raw = log return event, nil } // L2GatewayRouterMetaData contains all meta data concerning the L2GatewayRouter contract. var L2GatewayRouterMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"l1Token\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"l2Token\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"FinalizeDepositERC20\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"FinalizeDepositETH\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"name\":\"Initialized\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"previousOwner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"OwnershipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oldDefaultERC20Gateway\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"newDefaultERC20Gateway\",\"type\":\"address\"}],\"name\":\"SetDefaultERC20Gateway\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oldGateway\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"newGateway\",\"type\":\"address\"}],\"name\":\"SetERC20Gateway\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oldETHGateway\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"newEthGateway\",\"type\":\"address\"}],\"name\":\"SetETHGateway\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"l1Token\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"l2Token\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"WithdrawERC20\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"WithdrawETH\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"ERC20Gateway\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"defaultERC20Gateway\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"ethGateway\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"finalizeDepositERC20\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"finalizeDepositETH\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_token\",\"type\":\"address\"}],\"name\":\"getERC20Gateway\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_l2Address\",\"type\":\"address\"}],\"name\":\"getL1ERC20Address\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"getL2ERC20Address\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_ethGateway\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_defaultERC20Gateway\",\"type\":\"address\"}],\"name\":\"initialize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_newDefaultERC20Gateway\",\"type\":\"address\"}],\"name\":\"setDefaultERC20Gateway\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_tokens\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_gateways\",\"type\":\"address[]\"}],\"name\":\"setERC20Gateway\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_newEthGateway\",\"type\":\"address\"}],\"name\":\"setETHGateway\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_token\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_gasLimit\",\"type\":\"uint256\"}],\"name\":\"withdrawERC20\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_token\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_gasLimit\",\"type\":\"uint256\"}],\"name\":\"withdrawERC20\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_token\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"_data\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"_gasLimit\",\"type\":\"uint256\"}],\"name\":\"withdrawERC20AndCall\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_gasLimit\",\"type\":\"uint256\"}],\"name\":\"withdrawETH\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_gasLimit\",\"type\":\"uint256\"}],\"name\":\"withdrawETH\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"_data\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"_gasLimit\",\"type\":\"uint256\"}],\"name\":\"withdrawETHAndCall\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"}]", Sigs: map[string]string{ "705b05b8": "ERC20Gateway(address)", "ce8c3e06": "defaultERC20Gateway()", "8c00ce73": "ethGateway()", "8431f5c1": "finalizeDepositERC20(address,address,address,address,uint256,bytes)", "232e8748": "finalizeDepositETH(address,address,uint256,bytes)", "43c66741": "getERC20Gateway(address)", "54bbd59c": "getL1ERC20Address(address)", "c676ad29": "getL2ERC20Address(address)", "485cc955": "initialize(address,address)", "8da5cb5b": "owner()", "715018a6": "renounceOwnership()", "5dfd5b9a": "setDefaultERC20Gateway(address)", "635c8637": "setERC20Gateway(address[],address[])", "3d1d31c7": "setETHGateway(address)", "f2fde38b": "transferOwnership(address)", "a93a4af9": "withdrawERC20(address,address,uint256,uint256)", "6c07ea43": "withdrawERC20(address,uint256,uint256)", "575361b6": "withdrawERC20AndCall(address,address,uint256,bytes,uint256)", "2fcc29fa": "withdrawETH(address,uint256,uint256)", "c7cdea37": "withdrawETH(uint256,uint256)", "6dc24183": "withdrawETHAndCall(address,uint256,bytes,uint256)", }, Bin: "0x608060405234801561001057600080fd5b5061001961001e565b6100dd565b600054610100900460ff161561008a5760405162461bcd60e51b815260206004820152602760248201527f496e697469616c697a61626c653a20636f6e747261637420697320696e697469604482015266616c697a696e6760c81b606482015260840160405180910390fd5b60005460ff908116146100db576000805460ff191660ff9081179091556040519081527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b565b61199a806100ec6000396000f3fe60806040526004361061016a5760003560e01c80636dc24183116100cb5780638da5cb5b1161007f578063c7cdea3711610059578063c7cdea37146103aa578063ce8c3e06146103bd578063f2fde38b146103ea57600080fd5b80638da5cb5b1461034c578063a93a4af914610377578063c676ad291461038a57600080fd5b8063715018a6116100b0578063715018a6146102fc5780638431f5c1146103115780638c00ce731461031f57600080fd5b80636dc24183146102a6578063705b05b8146102b957600080fd5b806354bbd59c116101225780635dfd5b9a116101075780635dfd5b9a14610253578063635c8637146102735780636c07ea431461029357600080fd5b806354bbd59c14610220578063575361b61461024057600080fd5b80633d1d31c7116101535780633d1d31c71461019757806343c66741146101b7578063485cc9551461020057600080fd5b8063232e87481461016f5780632fcc29fa14610184575b600080fd5b61018261017d3660046112bb565b61040a565b005b61018261019236600461132e565b610471565b3480156101a357600080fd5b506101826101b2366004611363565b6104af565b3480156101c357600080fd5b506101d76101d2366004611363565b61052e565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390f35b34801561020c57600080fd5b5061018261021b366004611380565b61057e565b34801561022c57600080fd5b506101d761023b366004611363565b610827565b61018261024e3660046114c5565b6108f0565b34801561025f57600080fd5b5061018261026e366004611363565b610a54565b34801561027f57600080fd5b5061018261028e3660046115c2565b610ad3565b6101826102a136600461132e565b610d35565b6101826102b4366004611626565b610d6f565b3480156102c557600080fd5b506101d76102d4366004611363565b60676020526000908152604090205473ffffffffffffffffffffffffffffffffffffffff1681565b34801561030857600080fd5b50610182610ec6565b61018261017d366004611687565b34801561032b57600080fd5b506065546101d79073ffffffffffffffffffffffffffffffffffffffff1681565b34801561035857600080fd5b5060335473ffffffffffffffffffffffffffffffffffffffff166101d7565b61018261038536600461171f565b610eda565b34801561039657600080fd5b506101d76103a5366004611363565b610eed565b6101826103b8366004611765565b610f52565b3480156103c957600080fd5b506066546101d79073ffffffffffffffffffffffffffffffffffffffff1681565b3480156103f657600080fd5b50610182610405366004611363565b610f62565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f73686f756c64206e657665722062652063616c6c65640000000000000000000060448201526064015b60405180910390fd5b6104aa838360005b6040519080825280601f01601f1916602001820160405280156104a3576020820181803683370190505b5084610d6f565b505050565b6104b7611019565b6065805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681179093556040519116919082907fa1bfcc6dd729ad197a1180f44d5c12bcc630943df0874b9ed53da23165621b6a90600090a35050565b73ffffffffffffffffffffffffffffffffffffffff80821660009081526067602052604081205490911680610578575060665473ffffffffffffffffffffffffffffffffffffffff165b92915050565b600054610100900460ff161580801561059e5750600054600160ff909116105b806105b85750303b1580156105b8575060005460ff166001145b610644576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a65640000000000000000000000000000000000006064820152608401610468565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905580156106a257600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff166101001790555b6106aa61109a565b73ffffffffffffffffffffffffffffffffffffffff82161561073557606680547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff84169081179091556040516000907f2904fcae71038f87b116fd2875871e153722cabddd71de1b77473de263cd74d1908290a35b73ffffffffffffffffffffffffffffffffffffffff8316156107c057606580547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff85169081179091556040516000907fa1bfcc6dd729ad197a1180f44d5c12bcc630943df0874b9ed53da23165621b6a908290a35b80156104aa57600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a1505050565b6000806108338361052e565b905073ffffffffffffffffffffffffffffffffffffffff81166108595750600092915050565b6040517f54bbd59c00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301528216906354bbd59c90602401602060405180830381865afa1580156108c5573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108e99190611787565b9392505050565b60006108fb8661052e565b905073ffffffffffffffffffffffffffffffffffffffff811661097a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f206761746577617920617661696c61626c650000000000000000000000006044820152606401610468565b6000338460405160200161098f929190611808565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290527f575361b6000000000000000000000000000000000000000000000000000000008252915073ffffffffffffffffffffffffffffffffffffffff83169063575361b6903490610a19908b908b908b9088908b9060040161183f565b6000604051808303818588803b158015610a3257600080fd5b505af1158015610a46573d6000803e3d6000fd5b505050505050505050505050565b610a5c611019565b6066805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681179093556040519116919082907f2904fcae71038f87b116fd2875871e153722cabddd71de1b77473de263cd74d190600090a35050565b610adb611019565b8051825114610b46576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600f60248201527f6c656e677468206d69736d6174636800000000000000000000000000000000006044820152606401610468565b60005b82518110156104aa57600060676000858481518110610b6a57610b6a611890565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050828281518110610be157610be1611890565b602002602001015160676000868581518110610bff57610bff611890565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550828281518110610c9157610c91611890565b602002602001015173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16858481518110610cd857610cd8611890565b602002602001015173ffffffffffffffffffffffffffffffffffffffff167f0ead4808404683f66d413d788a768219ea9785c97889221193103841a5841eaf60405160405180910390a45080610d2d816118bf565b915050610b49565b6104aa83338460005b6040519080825280601f01601f191660200182016040528015610d68576020820181803683370190505b50856108f0565b60655473ffffffffffffffffffffffffffffffffffffffff1680610def576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f657468206761746577617920617661696c61626c6500000000000000000000006044820152606401610468565b60003384604051602001610e04929190611808565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290527f6dc24183000000000000000000000000000000000000000000000000000000008252915073ffffffffffffffffffffffffffffffffffffffff831690636dc24183903490610e8c908a908a9087908a9060040161191e565b6000604051808303818588803b158015610ea557600080fd5b505af1158015610eb9573d6000803e3d6000fd5b5050505050505050505050565b610ece611019565b610ed86000611139565b565b610ee78484846000610d3e565b50505050565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600b60248201527f756e737570706f727465640000000000000000000000000000000000000000006044820152600090606401610468565b610f5e33836000610479565b5050565b610f6a611019565b73ffffffffffffffffffffffffffffffffffffffff811661100d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f64647265737300000000000000000000000000000000000000000000000000006064820152608401610468565b61101681611139565b50565b60335473ffffffffffffffffffffffffffffffffffffffff163314610ed8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610468565b600054610100900460ff16611131576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e670000000000000000000000000000000000000000006064820152608401610468565b610ed86111b0565b6033805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b600054610100900460ff16611247576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e670000000000000000000000000000000000000000006064820152608401610468565b610ed833611139565b73ffffffffffffffffffffffffffffffffffffffff8116811461101657600080fd5b60008083601f84011261128457600080fd5b50813567ffffffffffffffff81111561129c57600080fd5b6020830191508360208285010111156112b457600080fd5b9250929050565b6000806000806000608086880312156112d357600080fd5b85356112de81611250565b945060208601356112ee81611250565b935060408601359250606086013567ffffffffffffffff81111561131157600080fd5b61131d88828901611272565b969995985093965092949392505050565b60008060006060848603121561134357600080fd5b833561134e81611250565b95602085013595506040909401359392505050565b60006020828403121561137557600080fd5b81356108e981611250565b6000806040838503121561139357600080fd5b823561139e81611250565b915060208301356113ae81611250565b809150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561142f5761142f6113b9565b604052919050565b600082601f83011261144857600080fd5b813567ffffffffffffffff811115611462576114626113b9565b61149360207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116016113e8565b8181528460208386010111156114a857600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080600060a086880312156114dd57600080fd5b85356114e881611250565b945060208601356114f881611250565b935060408601359250606086013567ffffffffffffffff81111561151b57600080fd5b61152788828901611437565b95989497509295608001359392505050565b600082601f83011261154a57600080fd5b8135602067ffffffffffffffff821115611566576115666113b9565b8160051b6115758282016113e8565b928352848101820192828101908785111561158f57600080fd5b83870192505b848310156115b75782356115a881611250565b82529183019190830190611595565b979650505050505050565b600080604083850312156115d557600080fd5b823567ffffffffffffffff808211156115ed57600080fd5b6115f986838701611539565b9350602085013591508082111561160f57600080fd5b5061161c85828601611539565b9150509250929050565b6000806000806080858703121561163c57600080fd5b843561164781611250565b935060208501359250604085013567ffffffffffffffff81111561166a57600080fd5b61167687828801611437565b949793965093946060013593505050565b600080600080600080600060c0888a0312156116a257600080fd5b87356116ad81611250565b965060208801356116bd81611250565b955060408801356116cd81611250565b945060608801356116dd81611250565b93506080880135925060a088013567ffffffffffffffff81111561170057600080fd5b61170c8a828b01611272565b989b979a50959850939692959293505050565b6000806000806080858703121561173557600080fd5b843561174081611250565b9350602085013561175081611250565b93969395505050506040820135916060013590565b6000806040838503121561177857600080fd5b50508035926020909101359150565b60006020828403121561179957600080fd5b81516108e981611250565b6000815180845260005b818110156117ca576020818501810151868301820152016117ae565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b73ffffffffffffffffffffffffffffffffffffffff8316815260406020820152600061183760408301846117a4565b949350505050565b600073ffffffffffffffffffffffffffffffffffffffff808816835280871660208401525084604083015260a0606083015261187e60a08301856117a4565b90508260808301529695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203611917577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b5060010190565b73ffffffffffffffffffffffffffffffffffffffff8516815283602082015260806040820152600061195360808301856117a4565b90508260608301529594505050505056fea264697066735822122073303dcce46a3b93525e9f6208db287fe6e07165d3eb592498565568b21f78a764736f6c63430008110033", } // L2GatewayRouterABI is the input ABI used to generate the binding from. // Deprecated: Use L2GatewayRouterMetaData.ABI instead. var L2GatewayRouterABI = L2GatewayRouterMetaData.ABI // Deprecated: Use L2GatewayRouterMetaData.Sigs instead. // L2GatewayRouterFuncSigs maps the 4-byte function signature to its string representation. var L2GatewayRouterFuncSigs = L2GatewayRouterMetaData.Sigs // L2GatewayRouterBin is the compiled bytecode used for deploying new contracts. // Deprecated: Use L2GatewayRouterMetaData.Bin instead. var L2GatewayRouterBin = L2GatewayRouterMetaData.Bin // DeployL2GatewayRouter deploys a new Ethereum contract, binding an instance of L2GatewayRouter to it. func DeployL2GatewayRouter(auth *bind.TransactOpts, backend bind.ContractBackend) (common.Address, *types.Transaction, *L2GatewayRouter, error) { parsed, err := L2GatewayRouterMetaData.GetAbi() if err != nil { return common.Address{}, nil, nil, err } if parsed == nil { return common.Address{}, nil, nil, errors.New("GetABI returned nil") } address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(L2GatewayRouterBin), backend) if err != nil { return common.Address{}, nil, nil, err } return address, tx, &L2GatewayRouter{L2GatewayRouterCaller: L2GatewayRouterCaller{contract: contract}, L2GatewayRouterTransactor: L2GatewayRouterTransactor{contract: contract}, L2GatewayRouterFilterer: L2GatewayRouterFilterer{contract: contract}}, nil } // L2GatewayRouter is an auto generated Go binding around an Ethereum contract. type L2GatewayRouter struct { L2GatewayRouterCaller // Read-only binding to the contract L2GatewayRouterTransactor // Write-only binding to the contract L2GatewayRouterFilterer // Log filterer for contract events } // L2GatewayRouterCaller is an auto generated read-only Go binding around an Ethereum contract. type L2GatewayRouterCaller struct { contract *bind.BoundContract // Generic contract wrapper for the low level calls } // L2GatewayRouterTransactor is an auto generated write-only Go binding around an Ethereum contract. type L2GatewayRouterTransactor struct { contract *bind.BoundContract // Generic contract wrapper for the low level calls } // L2GatewayRouterFilterer is an auto generated log filtering Go binding around an Ethereum contract events. type L2GatewayRouterFilterer struct { contract *bind.BoundContract // Generic contract wrapper for the low level calls } // L2GatewayRouterSession is an auto generated Go binding around an Ethereum contract, // with pre-set call and transact options. type L2GatewayRouterSession struct { Contract *L2GatewayRouter // 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 } // L2GatewayRouterCallerSession is an auto generated read-only Go binding around an Ethereum contract, // with pre-set call options. type L2GatewayRouterCallerSession struct { Contract *L2GatewayRouterCaller // Generic contract caller binding to set the session for CallOpts bind.CallOpts // Call options to use throughout this session } // L2GatewayRouterTransactorSession is an auto generated write-only Go binding around an Ethereum contract, // with pre-set transact options. type L2GatewayRouterTransactorSession struct { Contract *L2GatewayRouterTransactor // Generic contract transactor binding to set the session for TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session } // L2GatewayRouterRaw is an auto generated low-level Go binding around an Ethereum contract. type L2GatewayRouterRaw struct { Contract *L2GatewayRouter // Generic contract binding to access the raw methods on } // L2GatewayRouterCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract. type L2GatewayRouterCallerRaw struct { Contract *L2GatewayRouterCaller // Generic read-only contract binding to access the raw methods on } // L2GatewayRouterTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract. type L2GatewayRouterTransactorRaw struct { Contract *L2GatewayRouterTransactor // Generic write-only contract binding to access the raw methods on } // NewL2GatewayRouter creates a new instance of L2GatewayRouter, bound to a specific deployed contract. func NewL2GatewayRouter(address common.Address, backend bind.ContractBackend) (*L2GatewayRouter, error) { contract, err := bindL2GatewayRouter(address, backend, backend, backend) if err != nil { return nil, err } return &L2GatewayRouter{L2GatewayRouterCaller: L2GatewayRouterCaller{contract: contract}, L2GatewayRouterTransactor: L2GatewayRouterTransactor{contract: contract}, L2GatewayRouterFilterer: L2GatewayRouterFilterer{contract: contract}}, nil } // NewL2GatewayRouterCaller creates a new read-only instance of L2GatewayRouter, bound to a specific deployed contract. func NewL2GatewayRouterCaller(address common.Address, caller bind.ContractCaller) (*L2GatewayRouterCaller, error) { contract, err := bindL2GatewayRouter(address, caller, nil, nil) if err != nil { return nil, err } return &L2GatewayRouterCaller{contract: contract}, nil } // NewL2GatewayRouterTransactor creates a new write-only instance of L2GatewayRouter, bound to a specific deployed contract. func NewL2GatewayRouterTransactor(address common.Address, transactor bind.ContractTransactor) (*L2GatewayRouterTransactor, error) { contract, err := bindL2GatewayRouter(address, nil, transactor, nil) if err != nil { return nil, err } return &L2GatewayRouterTransactor{contract: contract}, nil } // NewL2GatewayRouterFilterer creates a new log filterer instance of L2GatewayRouter, bound to a specific deployed contract. func NewL2GatewayRouterFilterer(address common.Address, filterer bind.ContractFilterer) (*L2GatewayRouterFilterer, error) { contract, err := bindL2GatewayRouter(address, nil, nil, filterer) if err != nil { return nil, err } return &L2GatewayRouterFilterer{contract: contract}, nil } // bindL2GatewayRouter binds a generic wrapper to an already deployed contract. func bindL2GatewayRouter(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { parsed, err := L2GatewayRouterMetaData.GetAbi() 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 (_L2GatewayRouter *L2GatewayRouterRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { return _L2GatewayRouter.Contract.L2GatewayRouterCaller.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 (_L2GatewayRouter *L2GatewayRouterRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { return _L2GatewayRouter.Contract.L2GatewayRouterTransactor.contract.Transfer(opts) } // Transact invokes the (paid) contract method with params as input values. func (_L2GatewayRouter *L2GatewayRouterRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { return _L2GatewayRouter.Contract.L2GatewayRouterTransactor.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 (_L2GatewayRouter *L2GatewayRouterCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { return _L2GatewayRouter.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 (_L2GatewayRouter *L2GatewayRouterTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { return _L2GatewayRouter.Contract.contract.Transfer(opts) } // Transact invokes the (paid) contract method with params as input values. func (_L2GatewayRouter *L2GatewayRouterTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { return _L2GatewayRouter.Contract.contract.Transact(opts, method, params...) } // ERC20Gateway is a free data retrieval call binding the contract method 0x705b05b8. // // Solidity: function ERC20Gateway(address ) view returns(address) func (_L2GatewayRouter *L2GatewayRouterCaller) ERC20Gateway(opts *bind.CallOpts, arg0 common.Address) (common.Address, error) { var out []interface{} err := _L2GatewayRouter.contract.Call(opts, &out, "ERC20Gateway", arg0) if err != nil { return *new(common.Address), err } out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) return out0, err } // ERC20Gateway is a free data retrieval call binding the contract method 0x705b05b8. // // Solidity: function ERC20Gateway(address ) view returns(address) func (_L2GatewayRouter *L2GatewayRouterSession) ERC20Gateway(arg0 common.Address) (common.Address, error) { return _L2GatewayRouter.Contract.ERC20Gateway(&_L2GatewayRouter.CallOpts, arg0) } // ERC20Gateway is a free data retrieval call binding the contract method 0x705b05b8. // // Solidity: function ERC20Gateway(address ) view returns(address) func (_L2GatewayRouter *L2GatewayRouterCallerSession) ERC20Gateway(arg0 common.Address) (common.Address, error) { return _L2GatewayRouter.Contract.ERC20Gateway(&_L2GatewayRouter.CallOpts, arg0) } // DefaultERC20Gateway is a free data retrieval call binding the contract method 0xce8c3e06. // // Solidity: function defaultERC20Gateway() view returns(address) func (_L2GatewayRouter *L2GatewayRouterCaller) DefaultERC20Gateway(opts *bind.CallOpts) (common.Address, error) { var out []interface{} err := _L2GatewayRouter.contract.Call(opts, &out, "defaultERC20Gateway") if err != nil { return *new(common.Address), err } out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) return out0, err } // DefaultERC20Gateway is a free data retrieval call binding the contract method 0xce8c3e06. // // Solidity: function defaultERC20Gateway() view returns(address) func (_L2GatewayRouter *L2GatewayRouterSession) DefaultERC20Gateway() (common.Address, error) { return _L2GatewayRouter.Contract.DefaultERC20Gateway(&_L2GatewayRouter.CallOpts) } // DefaultERC20Gateway is a free data retrieval call binding the contract method 0xce8c3e06. // // Solidity: function defaultERC20Gateway() view returns(address) func (_L2GatewayRouter *L2GatewayRouterCallerSession) DefaultERC20Gateway() (common.Address, error) { return _L2GatewayRouter.Contract.DefaultERC20Gateway(&_L2GatewayRouter.CallOpts) } // EthGateway is a free data retrieval call binding the contract method 0x8c00ce73. // // Solidity: function ethGateway() view returns(address) func (_L2GatewayRouter *L2GatewayRouterCaller) EthGateway(opts *bind.CallOpts) (common.Address, error) { var out []interface{} err := _L2GatewayRouter.contract.Call(opts, &out, "ethGateway") if err != nil { return *new(common.Address), err } out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) return out0, err } // EthGateway is a free data retrieval call binding the contract method 0x8c00ce73. // // Solidity: function ethGateway() view returns(address) func (_L2GatewayRouter *L2GatewayRouterSession) EthGateway() (common.Address, error) { return _L2GatewayRouter.Contract.EthGateway(&_L2GatewayRouter.CallOpts) } // EthGateway is a free data retrieval call binding the contract method 0x8c00ce73. // // Solidity: function ethGateway() view returns(address) func (_L2GatewayRouter *L2GatewayRouterCallerSession) EthGateway() (common.Address, error) { return _L2GatewayRouter.Contract.EthGateway(&_L2GatewayRouter.CallOpts) } // GetERC20Gateway is a free data retrieval call binding the contract method 0x43c66741. // // Solidity: function getERC20Gateway(address _token) view returns(address) func (_L2GatewayRouter *L2GatewayRouterCaller) GetERC20Gateway(opts *bind.CallOpts, _token common.Address) (common.Address, error) { var out []interface{} err := _L2GatewayRouter.contract.Call(opts, &out, "getERC20Gateway", _token) if err != nil { return *new(common.Address), err } out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) return out0, err } // GetERC20Gateway is a free data retrieval call binding the contract method 0x43c66741. // // Solidity: function getERC20Gateway(address _token) view returns(address) func (_L2GatewayRouter *L2GatewayRouterSession) GetERC20Gateway(_token common.Address) (common.Address, error) { return _L2GatewayRouter.Contract.GetERC20Gateway(&_L2GatewayRouter.CallOpts, _token) } // GetERC20Gateway is a free data retrieval call binding the contract method 0x43c66741. // // Solidity: function getERC20Gateway(address _token) view returns(address) func (_L2GatewayRouter *L2GatewayRouterCallerSession) GetERC20Gateway(_token common.Address) (common.Address, error) { return _L2GatewayRouter.Contract.GetERC20Gateway(&_L2GatewayRouter.CallOpts, _token) } // GetL1ERC20Address is a free data retrieval call binding the contract method 0x54bbd59c. // // Solidity: function getL1ERC20Address(address _l2Address) view returns(address) func (_L2GatewayRouter *L2GatewayRouterCaller) GetL1ERC20Address(opts *bind.CallOpts, _l2Address common.Address) (common.Address, error) { var out []interface{} err := _L2GatewayRouter.contract.Call(opts, &out, "getL1ERC20Address", _l2Address) if err != nil { return *new(common.Address), err } out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) return out0, err } // GetL1ERC20Address is a free data retrieval call binding the contract method 0x54bbd59c. // // Solidity: function getL1ERC20Address(address _l2Address) view returns(address) func (_L2GatewayRouter *L2GatewayRouterSession) GetL1ERC20Address(_l2Address common.Address) (common.Address, error) { return _L2GatewayRouter.Contract.GetL1ERC20Address(&_L2GatewayRouter.CallOpts, _l2Address) } // GetL1ERC20Address is a free data retrieval call binding the contract method 0x54bbd59c. // // Solidity: function getL1ERC20Address(address _l2Address) view returns(address) func (_L2GatewayRouter *L2GatewayRouterCallerSession) GetL1ERC20Address(_l2Address common.Address) (common.Address, error) { return _L2GatewayRouter.Contract.GetL1ERC20Address(&_L2GatewayRouter.CallOpts, _l2Address) } // GetL2ERC20Address is a free data retrieval call binding the contract method 0xc676ad29. // // Solidity: function getL2ERC20Address(address ) pure returns(address) func (_L2GatewayRouter *L2GatewayRouterCaller) GetL2ERC20Address(opts *bind.CallOpts, arg0 common.Address) (common.Address, error) { var out []interface{} err := _L2GatewayRouter.contract.Call(opts, &out, "getL2ERC20Address", arg0) if err != nil { return *new(common.Address), err } out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) return out0, err } // GetL2ERC20Address is a free data retrieval call binding the contract method 0xc676ad29. // // Solidity: function getL2ERC20Address(address ) pure returns(address) func (_L2GatewayRouter *L2GatewayRouterSession) GetL2ERC20Address(arg0 common.Address) (common.Address, error) { return _L2GatewayRouter.Contract.GetL2ERC20Address(&_L2GatewayRouter.CallOpts, arg0) } // GetL2ERC20Address is a free data retrieval call binding the contract method 0xc676ad29. // // Solidity: function getL2ERC20Address(address ) pure returns(address) func (_L2GatewayRouter *L2GatewayRouterCallerSession) GetL2ERC20Address(arg0 common.Address) (common.Address, error) { return _L2GatewayRouter.Contract.GetL2ERC20Address(&_L2GatewayRouter.CallOpts, arg0) } // Owner is a free data retrieval call binding the contract method 0x8da5cb5b. // // Solidity: function owner() view returns(address) func (_L2GatewayRouter *L2GatewayRouterCaller) Owner(opts *bind.CallOpts) (common.Address, error) { var out []interface{} err := _L2GatewayRouter.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 (_L2GatewayRouter *L2GatewayRouterSession) Owner() (common.Address, error) { return _L2GatewayRouter.Contract.Owner(&_L2GatewayRouter.CallOpts) } // Owner is a free data retrieval call binding the contract method 0x8da5cb5b. // // Solidity: function owner() view returns(address) func (_L2GatewayRouter *L2GatewayRouterCallerSession) Owner() (common.Address, error) { return _L2GatewayRouter.Contract.Owner(&_L2GatewayRouter.CallOpts) } // FinalizeDepositERC20 is a paid mutator transaction binding the contract method 0x8431f5c1. // // Solidity: function finalizeDepositERC20(address , address , address , address , uint256 , bytes ) payable returns() func (_L2GatewayRouter *L2GatewayRouterTransactor) FinalizeDepositERC20(opts *bind.TransactOpts, arg0 common.Address, arg1 common.Address, arg2 common.Address, arg3 common.Address, arg4 *big.Int, arg5 []byte) (*types.Transaction, error) { return _L2GatewayRouter.contract.Transact(opts, "finalizeDepositERC20", arg0, arg1, arg2, arg3, arg4, arg5) } // FinalizeDepositERC20 is a paid mutator transaction binding the contract method 0x8431f5c1. // // Solidity: function finalizeDepositERC20(address , address , address , address , uint256 , bytes ) payable returns() func (_L2GatewayRouter *L2GatewayRouterSession) FinalizeDepositERC20(arg0 common.Address, arg1 common.Address, arg2 common.Address, arg3 common.Address, arg4 *big.Int, arg5 []byte) (*types.Transaction, error) { return _L2GatewayRouter.Contract.FinalizeDepositERC20(&_L2GatewayRouter.TransactOpts, arg0, arg1, arg2, arg3, arg4, arg5) } // FinalizeDepositERC20 is a paid mutator transaction binding the contract method 0x8431f5c1. // // Solidity: function finalizeDepositERC20(address , address , address , address , uint256 , bytes ) payable returns() func (_L2GatewayRouter *L2GatewayRouterTransactorSession) FinalizeDepositERC20(arg0 common.Address, arg1 common.Address, arg2 common.Address, arg3 common.Address, arg4 *big.Int, arg5 []byte) (*types.Transaction, error) { return _L2GatewayRouter.Contract.FinalizeDepositERC20(&_L2GatewayRouter.TransactOpts, arg0, arg1, arg2, arg3, arg4, arg5) } // FinalizeDepositETH is a paid mutator transaction binding the contract method 0x232e8748. // // Solidity: function finalizeDepositETH(address , address , uint256 , bytes ) payable returns() func (_L2GatewayRouter *L2GatewayRouterTransactor) FinalizeDepositETH(opts *bind.TransactOpts, arg0 common.Address, arg1 common.Address, arg2 *big.Int, arg3 []byte) (*types.Transaction, error) { return _L2GatewayRouter.contract.Transact(opts, "finalizeDepositETH", arg0, arg1, arg2, arg3) } // FinalizeDepositETH is a paid mutator transaction binding the contract method 0x232e8748. // // Solidity: function finalizeDepositETH(address , address , uint256 , bytes ) payable returns() func (_L2GatewayRouter *L2GatewayRouterSession) FinalizeDepositETH(arg0 common.Address, arg1 common.Address, arg2 *big.Int, arg3 []byte) (*types.Transaction, error) { return _L2GatewayRouter.Contract.FinalizeDepositETH(&_L2GatewayRouter.TransactOpts, arg0, arg1, arg2, arg3) } // FinalizeDepositETH is a paid mutator transaction binding the contract method 0x232e8748. // // Solidity: function finalizeDepositETH(address , address , uint256 , bytes ) payable returns() func (_L2GatewayRouter *L2GatewayRouterTransactorSession) FinalizeDepositETH(arg0 common.Address, arg1 common.Address, arg2 *big.Int, arg3 []byte) (*types.Transaction, error) { return _L2GatewayRouter.Contract.FinalizeDepositETH(&_L2GatewayRouter.TransactOpts, arg0, arg1, arg2, arg3) } // Initialize is a paid mutator transaction binding the contract method 0x485cc955. // // Solidity: function initialize(address _ethGateway, address _defaultERC20Gateway) returns() func (_L2GatewayRouter *L2GatewayRouterTransactor) Initialize(opts *bind.TransactOpts, _ethGateway common.Address, _defaultERC20Gateway common.Address) (*types.Transaction, error) { return _L2GatewayRouter.contract.Transact(opts, "initialize", _ethGateway, _defaultERC20Gateway) } // Initialize is a paid mutator transaction binding the contract method 0x485cc955. // // Solidity: function initialize(address _ethGateway, address _defaultERC20Gateway) returns() func (_L2GatewayRouter *L2GatewayRouterSession) Initialize(_ethGateway common.Address, _defaultERC20Gateway common.Address) (*types.Transaction, error) { return _L2GatewayRouter.Contract.Initialize(&_L2GatewayRouter.TransactOpts, _ethGateway, _defaultERC20Gateway) } // Initialize is a paid mutator transaction binding the contract method 0x485cc955. // // Solidity: function initialize(address _ethGateway, address _defaultERC20Gateway) returns() func (_L2GatewayRouter *L2GatewayRouterTransactorSession) Initialize(_ethGateway common.Address, _defaultERC20Gateway common.Address) (*types.Transaction, error) { return _L2GatewayRouter.Contract.Initialize(&_L2GatewayRouter.TransactOpts, _ethGateway, _defaultERC20Gateway) } // RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6. // // Solidity: function renounceOwnership() returns() func (_L2GatewayRouter *L2GatewayRouterTransactor) RenounceOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { return _L2GatewayRouter.contract.Transact(opts, "renounceOwnership") } // RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6. // // Solidity: function renounceOwnership() returns() func (_L2GatewayRouter *L2GatewayRouterSession) RenounceOwnership() (*types.Transaction, error) { return _L2GatewayRouter.Contract.RenounceOwnership(&_L2GatewayRouter.TransactOpts) } // RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6. // // Solidity: function renounceOwnership() returns() func (_L2GatewayRouter *L2GatewayRouterTransactorSession) RenounceOwnership() (*types.Transaction, error) { return _L2GatewayRouter.Contract.RenounceOwnership(&_L2GatewayRouter.TransactOpts) } // SetDefaultERC20Gateway is a paid mutator transaction binding the contract method 0x5dfd5b9a. // // Solidity: function setDefaultERC20Gateway(address _newDefaultERC20Gateway) returns() func (_L2GatewayRouter *L2GatewayRouterTransactor) SetDefaultERC20Gateway(opts *bind.TransactOpts, _newDefaultERC20Gateway common.Address) (*types.Transaction, error) { return _L2GatewayRouter.contract.Transact(opts, "setDefaultERC20Gateway", _newDefaultERC20Gateway) } // SetDefaultERC20Gateway is a paid mutator transaction binding the contract method 0x5dfd5b9a. // // Solidity: function setDefaultERC20Gateway(address _newDefaultERC20Gateway) returns() func (_L2GatewayRouter *L2GatewayRouterSession) SetDefaultERC20Gateway(_newDefaultERC20Gateway common.Address) (*types.Transaction, error) { return _L2GatewayRouter.Contract.SetDefaultERC20Gateway(&_L2GatewayRouter.TransactOpts, _newDefaultERC20Gateway) } // SetDefaultERC20Gateway is a paid mutator transaction binding the contract method 0x5dfd5b9a. // // Solidity: function setDefaultERC20Gateway(address _newDefaultERC20Gateway) returns() func (_L2GatewayRouter *L2GatewayRouterTransactorSession) SetDefaultERC20Gateway(_newDefaultERC20Gateway common.Address) (*types.Transaction, error) { return _L2GatewayRouter.Contract.SetDefaultERC20Gateway(&_L2GatewayRouter.TransactOpts, _newDefaultERC20Gateway) } // SetERC20Gateway is a paid mutator transaction binding the contract method 0x635c8637. // // Solidity: function setERC20Gateway(address[] _tokens, address[] _gateways) returns() func (_L2GatewayRouter *L2GatewayRouterTransactor) SetERC20Gateway(opts *bind.TransactOpts, _tokens []common.Address, _gateways []common.Address) (*types.Transaction, error) { return _L2GatewayRouter.contract.Transact(opts, "setERC20Gateway", _tokens, _gateways) } // SetERC20Gateway is a paid mutator transaction binding the contract method 0x635c8637. // // Solidity: function setERC20Gateway(address[] _tokens, address[] _gateways) returns() func (_L2GatewayRouter *L2GatewayRouterSession) SetERC20Gateway(_tokens []common.Address, _gateways []common.Address) (*types.Transaction, error) { return _L2GatewayRouter.Contract.SetERC20Gateway(&_L2GatewayRouter.TransactOpts, _tokens, _gateways) } // SetERC20Gateway is a paid mutator transaction binding the contract method 0x635c8637. // // Solidity: function setERC20Gateway(address[] _tokens, address[] _gateways) returns() func (_L2GatewayRouter *L2GatewayRouterTransactorSession) SetERC20Gateway(_tokens []common.Address, _gateways []common.Address) (*types.Transaction, error) { return _L2GatewayRouter.Contract.SetERC20Gateway(&_L2GatewayRouter.TransactOpts, _tokens, _gateways) } // SetETHGateway is a paid mutator transaction binding the contract method 0x3d1d31c7. // // Solidity: function setETHGateway(address _newEthGateway) returns() func (_L2GatewayRouter *L2GatewayRouterTransactor) SetETHGateway(opts *bind.TransactOpts, _newEthGateway common.Address) (*types.Transaction, error) { return _L2GatewayRouter.contract.Transact(opts, "setETHGateway", _newEthGateway) } // SetETHGateway is a paid mutator transaction binding the contract method 0x3d1d31c7. // // Solidity: function setETHGateway(address _newEthGateway) returns() func (_L2GatewayRouter *L2GatewayRouterSession) SetETHGateway(_newEthGateway common.Address) (*types.Transaction, error) { return _L2GatewayRouter.Contract.SetETHGateway(&_L2GatewayRouter.TransactOpts, _newEthGateway) } // SetETHGateway is a paid mutator transaction binding the contract method 0x3d1d31c7. // // Solidity: function setETHGateway(address _newEthGateway) returns() func (_L2GatewayRouter *L2GatewayRouterTransactorSession) SetETHGateway(_newEthGateway common.Address) (*types.Transaction, error) { return _L2GatewayRouter.Contract.SetETHGateway(&_L2GatewayRouter.TransactOpts, _newEthGateway) } // TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b. // // Solidity: function transferOwnership(address newOwner) returns() func (_L2GatewayRouter *L2GatewayRouterTransactor) TransferOwnership(opts *bind.TransactOpts, newOwner common.Address) (*types.Transaction, error) { return _L2GatewayRouter.contract.Transact(opts, "transferOwnership", newOwner) } // TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b. // // Solidity: function transferOwnership(address newOwner) returns() func (_L2GatewayRouter *L2GatewayRouterSession) TransferOwnership(newOwner common.Address) (*types.Transaction, error) { return _L2GatewayRouter.Contract.TransferOwnership(&_L2GatewayRouter.TransactOpts, newOwner) } // TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b. // // Solidity: function transferOwnership(address newOwner) returns() func (_L2GatewayRouter *L2GatewayRouterTransactorSession) TransferOwnership(newOwner common.Address) (*types.Transaction, error) { return _L2GatewayRouter.Contract.TransferOwnership(&_L2GatewayRouter.TransactOpts, newOwner) } // WithdrawERC20 is a paid mutator transaction binding the contract method 0x6c07ea43. // // Solidity: function withdrawERC20(address _token, uint256 _amount, uint256 _gasLimit) payable returns() func (_L2GatewayRouter *L2GatewayRouterTransactor) WithdrawERC20(opts *bind.TransactOpts, _token common.Address, _amount *big.Int, _gasLimit *big.Int) (*types.Transaction, error) { return _L2GatewayRouter.contract.Transact(opts, "withdrawERC20", _token, _amount, _gasLimit) } // WithdrawERC20 is a paid mutator transaction binding the contract method 0x6c07ea43. // // Solidity: function withdrawERC20(address _token, uint256 _amount, uint256 _gasLimit) payable returns() func (_L2GatewayRouter *L2GatewayRouterSession) WithdrawERC20(_token common.Address, _amount *big.Int, _gasLimit *big.Int) (*types.Transaction, error) { return _L2GatewayRouter.Contract.WithdrawERC20(&_L2GatewayRouter.TransactOpts, _token, _amount, _gasLimit) } // WithdrawERC20 is a paid mutator transaction binding the contract method 0x6c07ea43. // // Solidity: function withdrawERC20(address _token, uint256 _amount, uint256 _gasLimit) payable returns() func (_L2GatewayRouter *L2GatewayRouterTransactorSession) WithdrawERC20(_token common.Address, _amount *big.Int, _gasLimit *big.Int) (*types.Transaction, error) { return _L2GatewayRouter.Contract.WithdrawERC20(&_L2GatewayRouter.TransactOpts, _token, _amount, _gasLimit) } // WithdrawERC200 is a paid mutator transaction binding the contract method 0xa93a4af9. // // Solidity: function withdrawERC20(address _token, address _to, uint256 _amount, uint256 _gasLimit) payable returns() func (_L2GatewayRouter *L2GatewayRouterTransactor) WithdrawERC200(opts *bind.TransactOpts, _token common.Address, _to common.Address, _amount *big.Int, _gasLimit *big.Int) (*types.Transaction, error) { return _L2GatewayRouter.contract.Transact(opts, "withdrawERC200", _token, _to, _amount, _gasLimit) } // WithdrawERC200 is a paid mutator transaction binding the contract method 0xa93a4af9. // // Solidity: function withdrawERC20(address _token, address _to, uint256 _amount, uint256 _gasLimit) payable returns() func (_L2GatewayRouter *L2GatewayRouterSession) WithdrawERC200(_token common.Address, _to common.Address, _amount *big.Int, _gasLimit *big.Int) (*types.Transaction, error) { return _L2GatewayRouter.Contract.WithdrawERC200(&_L2GatewayRouter.TransactOpts, _token, _to, _amount, _gasLimit) } // WithdrawERC200 is a paid mutator transaction binding the contract method 0xa93a4af9. // // Solidity: function withdrawERC20(address _token, address _to, uint256 _amount, uint256 _gasLimit) payable returns() func (_L2GatewayRouter *L2GatewayRouterTransactorSession) WithdrawERC200(_token common.Address, _to common.Address, _amount *big.Int, _gasLimit *big.Int) (*types.Transaction, error) { return _L2GatewayRouter.Contract.WithdrawERC200(&_L2GatewayRouter.TransactOpts, _token, _to, _amount, _gasLimit) } // WithdrawERC20AndCall is a paid mutator transaction binding the contract method 0x575361b6. // // Solidity: function withdrawERC20AndCall(address _token, address _to, uint256 _amount, bytes _data, uint256 _gasLimit) payable returns() func (_L2GatewayRouter *L2GatewayRouterTransactor) WithdrawERC20AndCall(opts *bind.TransactOpts, _token common.Address, _to common.Address, _amount *big.Int, _data []byte, _gasLimit *big.Int) (*types.Transaction, error) { return _L2GatewayRouter.contract.Transact(opts, "withdrawERC20AndCall", _token, _to, _amount, _data, _gasLimit) } // WithdrawERC20AndCall is a paid mutator transaction binding the contract method 0x575361b6. // // Solidity: function withdrawERC20AndCall(address _token, address _to, uint256 _amount, bytes _data, uint256 _gasLimit) payable returns() func (_L2GatewayRouter *L2GatewayRouterSession) WithdrawERC20AndCall(_token common.Address, _to common.Address, _amount *big.Int, _data []byte, _gasLimit *big.Int) (*types.Transaction, error) { return _L2GatewayRouter.Contract.WithdrawERC20AndCall(&_L2GatewayRouter.TransactOpts, _token, _to, _amount, _data, _gasLimit) } // WithdrawERC20AndCall is a paid mutator transaction binding the contract method 0x575361b6. // // Solidity: function withdrawERC20AndCall(address _token, address _to, uint256 _amount, bytes _data, uint256 _gasLimit) payable returns() func (_L2GatewayRouter *L2GatewayRouterTransactorSession) WithdrawERC20AndCall(_token common.Address, _to common.Address, _amount *big.Int, _data []byte, _gasLimit *big.Int) (*types.Transaction, error) { return _L2GatewayRouter.Contract.WithdrawERC20AndCall(&_L2GatewayRouter.TransactOpts, _token, _to, _amount, _data, _gasLimit) } // WithdrawETH is a paid mutator transaction binding the contract method 0x2fcc29fa. // // Solidity: function withdrawETH(address _to, uint256 _amount, uint256 _gasLimit) payable returns() func (_L2GatewayRouter *L2GatewayRouterTransactor) WithdrawETH(opts *bind.TransactOpts, _to common.Address, _amount *big.Int, _gasLimit *big.Int) (*types.Transaction, error) { return _L2GatewayRouter.contract.Transact(opts, "withdrawETH", _to, _amount, _gasLimit) } // WithdrawETH is a paid mutator transaction binding the contract method 0x2fcc29fa. // // Solidity: function withdrawETH(address _to, uint256 _amount, uint256 _gasLimit) payable returns() func (_L2GatewayRouter *L2GatewayRouterSession) WithdrawETH(_to common.Address, _amount *big.Int, _gasLimit *big.Int) (*types.Transaction, error) { return _L2GatewayRouter.Contract.WithdrawETH(&_L2GatewayRouter.TransactOpts, _to, _amount, _gasLimit) } // WithdrawETH is a paid mutator transaction binding the contract method 0x2fcc29fa. // // Solidity: function withdrawETH(address _to, uint256 _amount, uint256 _gasLimit) payable returns() func (_L2GatewayRouter *L2GatewayRouterTransactorSession) WithdrawETH(_to common.Address, _amount *big.Int, _gasLimit *big.Int) (*types.Transaction, error) { return _L2GatewayRouter.Contract.WithdrawETH(&_L2GatewayRouter.TransactOpts, _to, _amount, _gasLimit) } // WithdrawETH0 is a paid mutator transaction binding the contract method 0xc7cdea37. // // Solidity: function withdrawETH(uint256 _amount, uint256 _gasLimit) payable returns() func (_L2GatewayRouter *L2GatewayRouterTransactor) WithdrawETH0(opts *bind.TransactOpts, _amount *big.Int, _gasLimit *big.Int) (*types.Transaction, error) { return _L2GatewayRouter.contract.Transact(opts, "withdrawETH0", _amount, _gasLimit) } // WithdrawETH0 is a paid mutator transaction binding the contract method 0xc7cdea37. // // Solidity: function withdrawETH(uint256 _amount, uint256 _gasLimit) payable returns() func (_L2GatewayRouter *L2GatewayRouterSession) WithdrawETH0(_amount *big.Int, _gasLimit *big.Int) (*types.Transaction, error) { return _L2GatewayRouter.Contract.WithdrawETH0(&_L2GatewayRouter.TransactOpts, _amount, _gasLimit) } // WithdrawETH0 is a paid mutator transaction binding the contract method 0xc7cdea37. // // Solidity: function withdrawETH(uint256 _amount, uint256 _gasLimit) payable returns() func (_L2GatewayRouter *L2GatewayRouterTransactorSession) WithdrawETH0(_amount *big.Int, _gasLimit *big.Int) (*types.Transaction, error) { return _L2GatewayRouter.Contract.WithdrawETH0(&_L2GatewayRouter.TransactOpts, _amount, _gasLimit) } // WithdrawETHAndCall is a paid mutator transaction binding the contract method 0x6dc24183. // // Solidity: function withdrawETHAndCall(address _to, uint256 _amount, bytes _data, uint256 _gasLimit) payable returns() func (_L2GatewayRouter *L2GatewayRouterTransactor) WithdrawETHAndCall(opts *bind.TransactOpts, _to common.Address, _amount *big.Int, _data []byte, _gasLimit *big.Int) (*types.Transaction, error) { return _L2GatewayRouter.contract.Transact(opts, "withdrawETHAndCall", _to, _amount, _data, _gasLimit) } // WithdrawETHAndCall is a paid mutator transaction binding the contract method 0x6dc24183. // // Solidity: function withdrawETHAndCall(address _to, uint256 _amount, bytes _data, uint256 _gasLimit) payable returns() func (_L2GatewayRouter *L2GatewayRouterSession) WithdrawETHAndCall(_to common.Address, _amount *big.Int, _data []byte, _gasLimit *big.Int) (*types.Transaction, error) { return _L2GatewayRouter.Contract.WithdrawETHAndCall(&_L2GatewayRouter.TransactOpts, _to, _amount, _data, _gasLimit) } // WithdrawETHAndCall is a paid mutator transaction binding the contract method 0x6dc24183. // // Solidity: function withdrawETHAndCall(address _to, uint256 _amount, bytes _data, uint256 _gasLimit) payable returns() func (_L2GatewayRouter *L2GatewayRouterTransactorSession) WithdrawETHAndCall(_to common.Address, _amount *big.Int, _data []byte, _gasLimit *big.Int) (*types.Transaction, error) { return _L2GatewayRouter.Contract.WithdrawETHAndCall(&_L2GatewayRouter.TransactOpts, _to, _amount, _data, _gasLimit) } // L2GatewayRouterFinalizeDepositERC20Iterator is returned from FilterFinalizeDepositERC20 and is used to iterate over the raw logs and unpacked data for FinalizeDepositERC20 events raised by the L2GatewayRouter contract. type L2GatewayRouterFinalizeDepositERC20Iterator struct { Event *L2GatewayRouterFinalizeDepositERC20 // 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 *L2GatewayRouterFinalizeDepositERC20Iterator) 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(L2GatewayRouterFinalizeDepositERC20) 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(L2GatewayRouterFinalizeDepositERC20) 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 *L2GatewayRouterFinalizeDepositERC20Iterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. func (it *L2GatewayRouterFinalizeDepositERC20Iterator) Close() error { it.sub.Unsubscribe() return nil } // L2GatewayRouterFinalizeDepositERC20 represents a FinalizeDepositERC20 event raised by the L2GatewayRouter contract. type L2GatewayRouterFinalizeDepositERC20 struct { L1Token common.Address L2Token common.Address From common.Address To common.Address Amount *big.Int Data []byte Raw types.Log // Blockchain specific contextual infos } // FilterFinalizeDepositERC20 is a free log retrieval operation binding the contract event 0x165ba69f6ab40c50cade6f65431801e5f9c7d7830b7545391920db039133ba34. // // Solidity: event FinalizeDepositERC20(address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data) func (_L2GatewayRouter *L2GatewayRouterFilterer) FilterFinalizeDepositERC20(opts *bind.FilterOpts, l1Token []common.Address, l2Token []common.Address, from []common.Address) (*L2GatewayRouterFinalizeDepositERC20Iterator, error) { var l1TokenRule []interface{} for _, l1TokenItem := range l1Token { l1TokenRule = append(l1TokenRule, l1TokenItem) } var l2TokenRule []interface{} for _, l2TokenItem := range l2Token { l2TokenRule = append(l2TokenRule, l2TokenItem) } var fromRule []interface{} for _, fromItem := range from { fromRule = append(fromRule, fromItem) } logs, sub, err := _L2GatewayRouter.contract.FilterLogs(opts, "FinalizeDepositERC20", l1TokenRule, l2TokenRule, fromRule) if err != nil { return nil, err } return &L2GatewayRouterFinalizeDepositERC20Iterator{contract: _L2GatewayRouter.contract, event: "FinalizeDepositERC20", logs: logs, sub: sub}, nil } // WatchFinalizeDepositERC20 is a free log subscription operation binding the contract event 0x165ba69f6ab40c50cade6f65431801e5f9c7d7830b7545391920db039133ba34. // // Solidity: event FinalizeDepositERC20(address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data) func (_L2GatewayRouter *L2GatewayRouterFilterer) WatchFinalizeDepositERC20(opts *bind.WatchOpts, sink chan<- *L2GatewayRouterFinalizeDepositERC20, l1Token []common.Address, l2Token []common.Address, from []common.Address) (event.Subscription, error) { var l1TokenRule []interface{} for _, l1TokenItem := range l1Token { l1TokenRule = append(l1TokenRule, l1TokenItem) } var l2TokenRule []interface{} for _, l2TokenItem := range l2Token { l2TokenRule = append(l2TokenRule, l2TokenItem) } var fromRule []interface{} for _, fromItem := range from { fromRule = append(fromRule, fromItem) } logs, sub, err := _L2GatewayRouter.contract.WatchLogs(opts, "FinalizeDepositERC20", l1TokenRule, l2TokenRule, fromRule) 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(L2GatewayRouterFinalizeDepositERC20) if err := _L2GatewayRouter.contract.UnpackLog(event, "FinalizeDepositERC20", 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 } // ParseFinalizeDepositERC20 is a log parse operation binding the contract event 0x165ba69f6ab40c50cade6f65431801e5f9c7d7830b7545391920db039133ba34. // // Solidity: event FinalizeDepositERC20(address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data) func (_L2GatewayRouter *L2GatewayRouterFilterer) ParseFinalizeDepositERC20(log types.Log) (*L2GatewayRouterFinalizeDepositERC20, error) { event := new(L2GatewayRouterFinalizeDepositERC20) if err := _L2GatewayRouter.contract.UnpackLog(event, "FinalizeDepositERC20", log); err != nil { return nil, err } event.Raw = log return event, nil } // L2GatewayRouterFinalizeDepositETHIterator is returned from FilterFinalizeDepositETH and is used to iterate over the raw logs and unpacked data for FinalizeDepositETH events raised by the L2GatewayRouter contract. type L2GatewayRouterFinalizeDepositETHIterator struct { Event *L2GatewayRouterFinalizeDepositETH // 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 *L2GatewayRouterFinalizeDepositETHIterator) 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(L2GatewayRouterFinalizeDepositETH) 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(L2GatewayRouterFinalizeDepositETH) 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 *L2GatewayRouterFinalizeDepositETHIterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. func (it *L2GatewayRouterFinalizeDepositETHIterator) Close() error { it.sub.Unsubscribe() return nil } // L2GatewayRouterFinalizeDepositETH represents a FinalizeDepositETH event raised by the L2GatewayRouter contract. type L2GatewayRouterFinalizeDepositETH struct { From common.Address To common.Address Amount *big.Int Data []byte Raw types.Log // Blockchain specific contextual infos } // FilterFinalizeDepositETH is a free log retrieval operation binding the contract event 0x9e86c356e14e24e26e3ce769bf8b87de38e0faa0ed0ca946fa09659aa606bd2d. // // Solidity: event FinalizeDepositETH(address indexed from, address indexed to, uint256 amount, bytes data) func (_L2GatewayRouter *L2GatewayRouterFilterer) FilterFinalizeDepositETH(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*L2GatewayRouterFinalizeDepositETHIterator, error) { var fromRule []interface{} for _, fromItem := range from { fromRule = append(fromRule, fromItem) } var toRule []interface{} for _, toItem := range to { toRule = append(toRule, toItem) } logs, sub, err := _L2GatewayRouter.contract.FilterLogs(opts, "FinalizeDepositETH", fromRule, toRule) if err != nil { return nil, err } return &L2GatewayRouterFinalizeDepositETHIterator{contract: _L2GatewayRouter.contract, event: "FinalizeDepositETH", logs: logs, sub: sub}, nil } // WatchFinalizeDepositETH is a free log subscription operation binding the contract event 0x9e86c356e14e24e26e3ce769bf8b87de38e0faa0ed0ca946fa09659aa606bd2d. // // Solidity: event FinalizeDepositETH(address indexed from, address indexed to, uint256 amount, bytes data) func (_L2GatewayRouter *L2GatewayRouterFilterer) WatchFinalizeDepositETH(opts *bind.WatchOpts, sink chan<- *L2GatewayRouterFinalizeDepositETH, from []common.Address, to []common.Address) (event.Subscription, error) { var fromRule []interface{} for _, fromItem := range from { fromRule = append(fromRule, fromItem) } var toRule []interface{} for _, toItem := range to { toRule = append(toRule, toItem) } logs, sub, err := _L2GatewayRouter.contract.WatchLogs(opts, "FinalizeDepositETH", fromRule, toRule) 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(L2GatewayRouterFinalizeDepositETH) if err := _L2GatewayRouter.contract.UnpackLog(event, "FinalizeDepositETH", 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 } // ParseFinalizeDepositETH is a log parse operation binding the contract event 0x9e86c356e14e24e26e3ce769bf8b87de38e0faa0ed0ca946fa09659aa606bd2d. // // Solidity: event FinalizeDepositETH(address indexed from, address indexed to, uint256 amount, bytes data) func (_L2GatewayRouter *L2GatewayRouterFilterer) ParseFinalizeDepositETH(log types.Log) (*L2GatewayRouterFinalizeDepositETH, error) { event := new(L2GatewayRouterFinalizeDepositETH) if err := _L2GatewayRouter.contract.UnpackLog(event, "FinalizeDepositETH", log); err != nil { return nil, err } event.Raw = log return event, nil } // L2GatewayRouterInitializedIterator is returned from FilterInitialized and is used to iterate over the raw logs and unpacked data for Initialized events raised by the L2GatewayRouter contract. type L2GatewayRouterInitializedIterator struct { Event *L2GatewayRouterInitialized // 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 *L2GatewayRouterInitializedIterator) 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(L2GatewayRouterInitialized) 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(L2GatewayRouterInitialized) 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 *L2GatewayRouterInitializedIterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. func (it *L2GatewayRouterInitializedIterator) Close() error { it.sub.Unsubscribe() return nil } // L2GatewayRouterInitialized represents a Initialized event raised by the L2GatewayRouter contract. type L2GatewayRouterInitialized struct { Version uint8 Raw types.Log // Blockchain specific contextual infos } // FilterInitialized is a free log retrieval operation binding the contract event 0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498. // // Solidity: event Initialized(uint8 version) func (_L2GatewayRouter *L2GatewayRouterFilterer) FilterInitialized(opts *bind.FilterOpts) (*L2GatewayRouterInitializedIterator, error) { logs, sub, err := _L2GatewayRouter.contract.FilterLogs(opts, "Initialized") if err != nil { return nil, err } return &L2GatewayRouterInitializedIterator{contract: _L2GatewayRouter.contract, event: "Initialized", logs: logs, sub: sub}, nil } // WatchInitialized is a free log subscription operation binding the contract event 0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498. // // Solidity: event Initialized(uint8 version) func (_L2GatewayRouter *L2GatewayRouterFilterer) WatchInitialized(opts *bind.WatchOpts, sink chan<- *L2GatewayRouterInitialized) (event.Subscription, error) { logs, sub, err := _L2GatewayRouter.contract.WatchLogs(opts, "Initialized") 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(L2GatewayRouterInitialized) if err := _L2GatewayRouter.contract.UnpackLog(event, "Initialized", 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 } // ParseInitialized is a log parse operation binding the contract event 0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498. // // Solidity: event Initialized(uint8 version) func (_L2GatewayRouter *L2GatewayRouterFilterer) ParseInitialized(log types.Log) (*L2GatewayRouterInitialized, error) { event := new(L2GatewayRouterInitialized) if err := _L2GatewayRouter.contract.UnpackLog(event, "Initialized", log); err != nil { return nil, err } event.Raw = log return event, nil } // L2GatewayRouterOwnershipTransferredIterator is returned from FilterOwnershipTransferred and is used to iterate over the raw logs and unpacked data for OwnershipTransferred events raised by the L2GatewayRouter contract. type L2GatewayRouterOwnershipTransferredIterator struct { Event *L2GatewayRouterOwnershipTransferred // 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 *L2GatewayRouterOwnershipTransferredIterator) 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(L2GatewayRouterOwnershipTransferred) 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(L2GatewayRouterOwnershipTransferred) 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 *L2GatewayRouterOwnershipTransferredIterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. func (it *L2GatewayRouterOwnershipTransferredIterator) Close() error { it.sub.Unsubscribe() return nil } // L2GatewayRouterOwnershipTransferred represents a OwnershipTransferred event raised by the L2GatewayRouter contract. type L2GatewayRouterOwnershipTransferred 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 (_L2GatewayRouter *L2GatewayRouterFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, previousOwner []common.Address, newOwner []common.Address) (*L2GatewayRouterOwnershipTransferredIterator, 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 := _L2GatewayRouter.contract.FilterLogs(opts, "OwnershipTransferred", previousOwnerRule, newOwnerRule) if err != nil { return nil, err } return &L2GatewayRouterOwnershipTransferredIterator{contract: _L2GatewayRouter.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 (_L2GatewayRouter *L2GatewayRouterFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *L2GatewayRouterOwnershipTransferred, 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 := _L2GatewayRouter.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(L2GatewayRouterOwnershipTransferred) if err := _L2GatewayRouter.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 (_L2GatewayRouter *L2GatewayRouterFilterer) ParseOwnershipTransferred(log types.Log) (*L2GatewayRouterOwnershipTransferred, error) { event := new(L2GatewayRouterOwnershipTransferred) if err := _L2GatewayRouter.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { return nil, err } event.Raw = log return event, nil } // L2GatewayRouterSetDefaultERC20GatewayIterator is returned from FilterSetDefaultERC20Gateway and is used to iterate over the raw logs and unpacked data for SetDefaultERC20Gateway events raised by the L2GatewayRouter contract. type L2GatewayRouterSetDefaultERC20GatewayIterator struct { Event *L2GatewayRouterSetDefaultERC20Gateway // 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 *L2GatewayRouterSetDefaultERC20GatewayIterator) 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(L2GatewayRouterSetDefaultERC20Gateway) 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(L2GatewayRouterSetDefaultERC20Gateway) 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 *L2GatewayRouterSetDefaultERC20GatewayIterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. func (it *L2GatewayRouterSetDefaultERC20GatewayIterator) Close() error { it.sub.Unsubscribe() return nil } // L2GatewayRouterSetDefaultERC20Gateway represents a SetDefaultERC20Gateway event raised by the L2GatewayRouter contract. type L2GatewayRouterSetDefaultERC20Gateway struct { OldDefaultERC20Gateway common.Address NewDefaultERC20Gateway common.Address Raw types.Log // Blockchain specific contextual infos } // FilterSetDefaultERC20Gateway is a free log retrieval operation binding the contract event 0x2904fcae71038f87b116fd2875871e153722cabddd71de1b77473de263cd74d1. // // Solidity: event SetDefaultERC20Gateway(address indexed oldDefaultERC20Gateway, address indexed newDefaultERC20Gateway) func (_L2GatewayRouter *L2GatewayRouterFilterer) FilterSetDefaultERC20Gateway(opts *bind.FilterOpts, oldDefaultERC20Gateway []common.Address, newDefaultERC20Gateway []common.Address) (*L2GatewayRouterSetDefaultERC20GatewayIterator, error) { var oldDefaultERC20GatewayRule []interface{} for _, oldDefaultERC20GatewayItem := range oldDefaultERC20Gateway { oldDefaultERC20GatewayRule = append(oldDefaultERC20GatewayRule, oldDefaultERC20GatewayItem) } var newDefaultERC20GatewayRule []interface{} for _, newDefaultERC20GatewayItem := range newDefaultERC20Gateway { newDefaultERC20GatewayRule = append(newDefaultERC20GatewayRule, newDefaultERC20GatewayItem) } logs, sub, err := _L2GatewayRouter.contract.FilterLogs(opts, "SetDefaultERC20Gateway", oldDefaultERC20GatewayRule, newDefaultERC20GatewayRule) if err != nil { return nil, err } return &L2GatewayRouterSetDefaultERC20GatewayIterator{contract: _L2GatewayRouter.contract, event: "SetDefaultERC20Gateway", logs: logs, sub: sub}, nil } // WatchSetDefaultERC20Gateway is a free log subscription operation binding the contract event 0x2904fcae71038f87b116fd2875871e153722cabddd71de1b77473de263cd74d1. // // Solidity: event SetDefaultERC20Gateway(address indexed oldDefaultERC20Gateway, address indexed newDefaultERC20Gateway) func (_L2GatewayRouter *L2GatewayRouterFilterer) WatchSetDefaultERC20Gateway(opts *bind.WatchOpts, sink chan<- *L2GatewayRouterSetDefaultERC20Gateway, oldDefaultERC20Gateway []common.Address, newDefaultERC20Gateway []common.Address) (event.Subscription, error) { var oldDefaultERC20GatewayRule []interface{} for _, oldDefaultERC20GatewayItem := range oldDefaultERC20Gateway { oldDefaultERC20GatewayRule = append(oldDefaultERC20GatewayRule, oldDefaultERC20GatewayItem) } var newDefaultERC20GatewayRule []interface{} for _, newDefaultERC20GatewayItem := range newDefaultERC20Gateway { newDefaultERC20GatewayRule = append(newDefaultERC20GatewayRule, newDefaultERC20GatewayItem) } logs, sub, err := _L2GatewayRouter.contract.WatchLogs(opts, "SetDefaultERC20Gateway", oldDefaultERC20GatewayRule, newDefaultERC20GatewayRule) 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(L2GatewayRouterSetDefaultERC20Gateway) if err := _L2GatewayRouter.contract.UnpackLog(event, "SetDefaultERC20Gateway", 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 } // ParseSetDefaultERC20Gateway is a log parse operation binding the contract event 0x2904fcae71038f87b116fd2875871e153722cabddd71de1b77473de263cd74d1. // // Solidity: event SetDefaultERC20Gateway(address indexed oldDefaultERC20Gateway, address indexed newDefaultERC20Gateway) func (_L2GatewayRouter *L2GatewayRouterFilterer) ParseSetDefaultERC20Gateway(log types.Log) (*L2GatewayRouterSetDefaultERC20Gateway, error) { event := new(L2GatewayRouterSetDefaultERC20Gateway) if err := _L2GatewayRouter.contract.UnpackLog(event, "SetDefaultERC20Gateway", log); err != nil { return nil, err } event.Raw = log return event, nil } // L2GatewayRouterSetERC20GatewayIterator is returned from FilterSetERC20Gateway and is used to iterate over the raw logs and unpacked data for SetERC20Gateway events raised by the L2GatewayRouter contract. type L2GatewayRouterSetERC20GatewayIterator struct { Event *L2GatewayRouterSetERC20Gateway // 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 *L2GatewayRouterSetERC20GatewayIterator) 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(L2GatewayRouterSetERC20Gateway) 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(L2GatewayRouterSetERC20Gateway) 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 *L2GatewayRouterSetERC20GatewayIterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. func (it *L2GatewayRouterSetERC20GatewayIterator) Close() error { it.sub.Unsubscribe() return nil } // L2GatewayRouterSetERC20Gateway represents a SetERC20Gateway event raised by the L2GatewayRouter contract. type L2GatewayRouterSetERC20Gateway struct { Token common.Address OldGateway common.Address NewGateway common.Address Raw types.Log // Blockchain specific contextual infos } // FilterSetERC20Gateway is a free log retrieval operation binding the contract event 0x0ead4808404683f66d413d788a768219ea9785c97889221193103841a5841eaf. // // Solidity: event SetERC20Gateway(address indexed token, address indexed oldGateway, address indexed newGateway) func (_L2GatewayRouter *L2GatewayRouterFilterer) FilterSetERC20Gateway(opts *bind.FilterOpts, token []common.Address, oldGateway []common.Address, newGateway []common.Address) (*L2GatewayRouterSetERC20GatewayIterator, error) { var tokenRule []interface{} for _, tokenItem := range token { tokenRule = append(tokenRule, tokenItem) } var oldGatewayRule []interface{} for _, oldGatewayItem := range oldGateway { oldGatewayRule = append(oldGatewayRule, oldGatewayItem) } var newGatewayRule []interface{} for _, newGatewayItem := range newGateway { newGatewayRule = append(newGatewayRule, newGatewayItem) } logs, sub, err := _L2GatewayRouter.contract.FilterLogs(opts, "SetERC20Gateway", tokenRule, oldGatewayRule, newGatewayRule) if err != nil { return nil, err } return &L2GatewayRouterSetERC20GatewayIterator{contract: _L2GatewayRouter.contract, event: "SetERC20Gateway", logs: logs, sub: sub}, nil } // WatchSetERC20Gateway is a free log subscription operation binding the contract event 0x0ead4808404683f66d413d788a768219ea9785c97889221193103841a5841eaf. // // Solidity: event SetERC20Gateway(address indexed token, address indexed oldGateway, address indexed newGateway) func (_L2GatewayRouter *L2GatewayRouterFilterer) WatchSetERC20Gateway(opts *bind.WatchOpts, sink chan<- *L2GatewayRouterSetERC20Gateway, token []common.Address, oldGateway []common.Address, newGateway []common.Address) (event.Subscription, error) { var tokenRule []interface{} for _, tokenItem := range token { tokenRule = append(tokenRule, tokenItem) } var oldGatewayRule []interface{} for _, oldGatewayItem := range oldGateway { oldGatewayRule = append(oldGatewayRule, oldGatewayItem) } var newGatewayRule []interface{} for _, newGatewayItem := range newGateway { newGatewayRule = append(newGatewayRule, newGatewayItem) } logs, sub, err := _L2GatewayRouter.contract.WatchLogs(opts, "SetERC20Gateway", tokenRule, oldGatewayRule, newGatewayRule) 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(L2GatewayRouterSetERC20Gateway) if err := _L2GatewayRouter.contract.UnpackLog(event, "SetERC20Gateway", 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 } // ParseSetERC20Gateway is a log parse operation binding the contract event 0x0ead4808404683f66d413d788a768219ea9785c97889221193103841a5841eaf. // // Solidity: event SetERC20Gateway(address indexed token, address indexed oldGateway, address indexed newGateway) func (_L2GatewayRouter *L2GatewayRouterFilterer) ParseSetERC20Gateway(log types.Log) (*L2GatewayRouterSetERC20Gateway, error) { event := new(L2GatewayRouterSetERC20Gateway) if err := _L2GatewayRouter.contract.UnpackLog(event, "SetERC20Gateway", log); err != nil { return nil, err } event.Raw = log return event, nil } // L2GatewayRouterSetETHGatewayIterator is returned from FilterSetETHGateway and is used to iterate over the raw logs and unpacked data for SetETHGateway events raised by the L2GatewayRouter contract. type L2GatewayRouterSetETHGatewayIterator struct { Event *L2GatewayRouterSetETHGateway // 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 *L2GatewayRouterSetETHGatewayIterator) 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(L2GatewayRouterSetETHGateway) 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(L2GatewayRouterSetETHGateway) 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 *L2GatewayRouterSetETHGatewayIterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. func (it *L2GatewayRouterSetETHGatewayIterator) Close() error { it.sub.Unsubscribe() return nil } // L2GatewayRouterSetETHGateway represents a SetETHGateway event raised by the L2GatewayRouter contract. type L2GatewayRouterSetETHGateway struct { OldETHGateway common.Address NewEthGateway common.Address Raw types.Log // Blockchain specific contextual infos } // FilterSetETHGateway is a free log retrieval operation binding the contract event 0xa1bfcc6dd729ad197a1180f44d5c12bcc630943df0874b9ed53da23165621b6a. // // Solidity: event SetETHGateway(address indexed oldETHGateway, address indexed newEthGateway) func (_L2GatewayRouter *L2GatewayRouterFilterer) FilterSetETHGateway(opts *bind.FilterOpts, oldETHGateway []common.Address, newEthGateway []common.Address) (*L2GatewayRouterSetETHGatewayIterator, error) { var oldETHGatewayRule []interface{} for _, oldETHGatewayItem := range oldETHGateway { oldETHGatewayRule = append(oldETHGatewayRule, oldETHGatewayItem) } var newEthGatewayRule []interface{} for _, newEthGatewayItem := range newEthGateway { newEthGatewayRule = append(newEthGatewayRule, newEthGatewayItem) } logs, sub, err := _L2GatewayRouter.contract.FilterLogs(opts, "SetETHGateway", oldETHGatewayRule, newEthGatewayRule) if err != nil { return nil, err } return &L2GatewayRouterSetETHGatewayIterator{contract: _L2GatewayRouter.contract, event: "SetETHGateway", logs: logs, sub: sub}, nil } // WatchSetETHGateway is a free log subscription operation binding the contract event 0xa1bfcc6dd729ad197a1180f44d5c12bcc630943df0874b9ed53da23165621b6a. // // Solidity: event SetETHGateway(address indexed oldETHGateway, address indexed newEthGateway) func (_L2GatewayRouter *L2GatewayRouterFilterer) WatchSetETHGateway(opts *bind.WatchOpts, sink chan<- *L2GatewayRouterSetETHGateway, oldETHGateway []common.Address, newEthGateway []common.Address) (event.Subscription, error) { var oldETHGatewayRule []interface{} for _, oldETHGatewayItem := range oldETHGateway { oldETHGatewayRule = append(oldETHGatewayRule, oldETHGatewayItem) } var newEthGatewayRule []interface{} for _, newEthGatewayItem := range newEthGateway { newEthGatewayRule = append(newEthGatewayRule, newEthGatewayItem) } logs, sub, err := _L2GatewayRouter.contract.WatchLogs(opts, "SetETHGateway", oldETHGatewayRule, newEthGatewayRule) 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(L2GatewayRouterSetETHGateway) if err := _L2GatewayRouter.contract.UnpackLog(event, "SetETHGateway", 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 } // ParseSetETHGateway is a log parse operation binding the contract event 0xa1bfcc6dd729ad197a1180f44d5c12bcc630943df0874b9ed53da23165621b6a. // // Solidity: event SetETHGateway(address indexed oldETHGateway, address indexed newEthGateway) func (_L2GatewayRouter *L2GatewayRouterFilterer) ParseSetETHGateway(log types.Log) (*L2GatewayRouterSetETHGateway, error) { event := new(L2GatewayRouterSetETHGateway) if err := _L2GatewayRouter.contract.UnpackLog(event, "SetETHGateway", log); err != nil { return nil, err } event.Raw = log return event, nil } // L2GatewayRouterWithdrawERC20Iterator is returned from FilterWithdrawERC20 and is used to iterate over the raw logs and unpacked data for WithdrawERC20 events raised by the L2GatewayRouter contract. type L2GatewayRouterWithdrawERC20Iterator struct { Event *L2GatewayRouterWithdrawERC20 // 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 *L2GatewayRouterWithdrawERC20Iterator) 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(L2GatewayRouterWithdrawERC20) 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(L2GatewayRouterWithdrawERC20) 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 *L2GatewayRouterWithdrawERC20Iterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. func (it *L2GatewayRouterWithdrawERC20Iterator) Close() error { it.sub.Unsubscribe() return nil } // L2GatewayRouterWithdrawERC20 represents a WithdrawERC20 event raised by the L2GatewayRouter contract. type L2GatewayRouterWithdrawERC20 struct { L1Token common.Address L2Token common.Address From common.Address To common.Address Amount *big.Int Data []byte Raw types.Log // Blockchain specific contextual infos } // FilterWithdrawERC20 is a free log retrieval operation binding the contract event 0xd8d3a3f4ab95694bef40475997598bcf8acd3ed9617a4c1013795429414c27e8. // // Solidity: event WithdrawERC20(address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data) func (_L2GatewayRouter *L2GatewayRouterFilterer) FilterWithdrawERC20(opts *bind.FilterOpts, l1Token []common.Address, l2Token []common.Address, from []common.Address) (*L2GatewayRouterWithdrawERC20Iterator, error) { var l1TokenRule []interface{} for _, l1TokenItem := range l1Token { l1TokenRule = append(l1TokenRule, l1TokenItem) } var l2TokenRule []interface{} for _, l2TokenItem := range l2Token { l2TokenRule = append(l2TokenRule, l2TokenItem) } var fromRule []interface{} for _, fromItem := range from { fromRule = append(fromRule, fromItem) } logs, sub, err := _L2GatewayRouter.contract.FilterLogs(opts, "WithdrawERC20", l1TokenRule, l2TokenRule, fromRule) if err != nil { return nil, err } return &L2GatewayRouterWithdrawERC20Iterator{contract: _L2GatewayRouter.contract, event: "WithdrawERC20", logs: logs, sub: sub}, nil } // WatchWithdrawERC20 is a free log subscription operation binding the contract event 0xd8d3a3f4ab95694bef40475997598bcf8acd3ed9617a4c1013795429414c27e8. // // Solidity: event WithdrawERC20(address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data) func (_L2GatewayRouter *L2GatewayRouterFilterer) WatchWithdrawERC20(opts *bind.WatchOpts, sink chan<- *L2GatewayRouterWithdrawERC20, l1Token []common.Address, l2Token []common.Address, from []common.Address) (event.Subscription, error) { var l1TokenRule []interface{} for _, l1TokenItem := range l1Token { l1TokenRule = append(l1TokenRule, l1TokenItem) } var l2TokenRule []interface{} for _, l2TokenItem := range l2Token { l2TokenRule = append(l2TokenRule, l2TokenItem) } var fromRule []interface{} for _, fromItem := range from { fromRule = append(fromRule, fromItem) } logs, sub, err := _L2GatewayRouter.contract.WatchLogs(opts, "WithdrawERC20", l1TokenRule, l2TokenRule, fromRule) 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(L2GatewayRouterWithdrawERC20) if err := _L2GatewayRouter.contract.UnpackLog(event, "WithdrawERC20", 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 } // ParseWithdrawERC20 is a log parse operation binding the contract event 0xd8d3a3f4ab95694bef40475997598bcf8acd3ed9617a4c1013795429414c27e8. // // Solidity: event WithdrawERC20(address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data) func (_L2GatewayRouter *L2GatewayRouterFilterer) ParseWithdrawERC20(log types.Log) (*L2GatewayRouterWithdrawERC20, error) { event := new(L2GatewayRouterWithdrawERC20) if err := _L2GatewayRouter.contract.UnpackLog(event, "WithdrawERC20", log); err != nil { return nil, err } event.Raw = log return event, nil } // L2GatewayRouterWithdrawETHIterator is returned from FilterWithdrawETH and is used to iterate over the raw logs and unpacked data for WithdrawETH events raised by the L2GatewayRouter contract. type L2GatewayRouterWithdrawETHIterator struct { Event *L2GatewayRouterWithdrawETH // 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 *L2GatewayRouterWithdrawETHIterator) 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(L2GatewayRouterWithdrawETH) 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(L2GatewayRouterWithdrawETH) 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 *L2GatewayRouterWithdrawETHIterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. func (it *L2GatewayRouterWithdrawETHIterator) Close() error { it.sub.Unsubscribe() return nil } // L2GatewayRouterWithdrawETH represents a WithdrawETH event raised by the L2GatewayRouter contract. type L2GatewayRouterWithdrawETH struct { From common.Address To common.Address Amount *big.Int Data []byte Raw types.Log // Blockchain specific contextual infos } // FilterWithdrawETH is a free log retrieval operation binding the contract event 0xd8ed6eaa9a7a8980d7901e911fde6686810b989d3082182d1d3a3df6306ce20e. // // Solidity: event WithdrawETH(address indexed from, address indexed to, uint256 amount, bytes data) func (_L2GatewayRouter *L2GatewayRouterFilterer) FilterWithdrawETH(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*L2GatewayRouterWithdrawETHIterator, error) { var fromRule []interface{} for _, fromItem := range from { fromRule = append(fromRule, fromItem) } var toRule []interface{} for _, toItem := range to { toRule = append(toRule, toItem) } logs, sub, err := _L2GatewayRouter.contract.FilterLogs(opts, "WithdrawETH", fromRule, toRule) if err != nil { return nil, err } return &L2GatewayRouterWithdrawETHIterator{contract: _L2GatewayRouter.contract, event: "WithdrawETH", logs: logs, sub: sub}, nil } // WatchWithdrawETH is a free log subscription operation binding the contract event 0xd8ed6eaa9a7a8980d7901e911fde6686810b989d3082182d1d3a3df6306ce20e. // // Solidity: event WithdrawETH(address indexed from, address indexed to, uint256 amount, bytes data) func (_L2GatewayRouter *L2GatewayRouterFilterer) WatchWithdrawETH(opts *bind.WatchOpts, sink chan<- *L2GatewayRouterWithdrawETH, from []common.Address, to []common.Address) (event.Subscription, error) { var fromRule []interface{} for _, fromItem := range from { fromRule = append(fromRule, fromItem) } var toRule []interface{} for _, toItem := range to { toRule = append(toRule, toItem) } logs, sub, err := _L2GatewayRouter.contract.WatchLogs(opts, "WithdrawETH", fromRule, toRule) 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(L2GatewayRouterWithdrawETH) if err := _L2GatewayRouter.contract.UnpackLog(event, "WithdrawETH", 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 } // ParseWithdrawETH is a log parse operation binding the contract event 0xd8ed6eaa9a7a8980d7901e911fde6686810b989d3082182d1d3a3df6306ce20e. // // Solidity: event WithdrawETH(address indexed from, address indexed to, uint256 amount, bytes data) func (_L2GatewayRouter *L2GatewayRouterFilterer) ParseWithdrawETH(log types.Log) (*L2GatewayRouterWithdrawETH, error) { event := new(L2GatewayRouterWithdrawETH) if err := _L2GatewayRouter.contract.UnpackLog(event, "WithdrawETH", log); err != nil { return nil, err } event.Raw = log return event, nil } // OwnableUpgradeableMetaData contains all meta data concerning the OwnableUpgradeable contract. var OwnableUpgradeableMetaData = &bind.MetaData{ ABI: "[{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"name\":\"Initialized\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"previousOwner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"OwnershipTransferred\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", Sigs: map[string]string{ "8da5cb5b": "owner()", "715018a6": "renounceOwnership()", "f2fde38b": "transferOwnership(address)", }, } // OwnableUpgradeableABI is the input ABI used to generate the binding from. // Deprecated: Use OwnableUpgradeableMetaData.ABI instead. var OwnableUpgradeableABI = OwnableUpgradeableMetaData.ABI // Deprecated: Use OwnableUpgradeableMetaData.Sigs instead. // OwnableUpgradeableFuncSigs maps the 4-byte function signature to its string representation. var OwnableUpgradeableFuncSigs = OwnableUpgradeableMetaData.Sigs // OwnableUpgradeable is an auto generated Go binding around an Ethereum contract. type OwnableUpgradeable struct { OwnableUpgradeableCaller // Read-only binding to the contract OwnableUpgradeableTransactor // Write-only binding to the contract OwnableUpgradeableFilterer // Log filterer for contract events } // OwnableUpgradeableCaller is an auto generated read-only Go binding around an Ethereum contract. type OwnableUpgradeableCaller struct { contract *bind.BoundContract // Generic contract wrapper for the low level calls } // OwnableUpgradeableTransactor is an auto generated write-only Go binding around an Ethereum contract. type OwnableUpgradeableTransactor struct { contract *bind.BoundContract // Generic contract wrapper for the low level calls } // OwnableUpgradeableFilterer is an auto generated log filtering Go binding around an Ethereum contract events. type OwnableUpgradeableFilterer struct { contract *bind.BoundContract // Generic contract wrapper for the low level calls } // OwnableUpgradeableSession is an auto generated Go binding around an Ethereum contract, // with pre-set call and transact options. type OwnableUpgradeableSession struct { Contract *OwnableUpgradeable // 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 } // OwnableUpgradeableCallerSession is an auto generated read-only Go binding around an Ethereum contract, // with pre-set call options. type OwnableUpgradeableCallerSession struct { Contract *OwnableUpgradeableCaller // Generic contract caller binding to set the session for CallOpts bind.CallOpts // Call options to use throughout this session } // OwnableUpgradeableTransactorSession is an auto generated write-only Go binding around an Ethereum contract, // with pre-set transact options. type OwnableUpgradeableTransactorSession struct { Contract *OwnableUpgradeableTransactor // Generic contract transactor binding to set the session for TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session } // OwnableUpgradeableRaw is an auto generated low-level Go binding around an Ethereum contract. type OwnableUpgradeableRaw struct { Contract *OwnableUpgradeable // Generic contract binding to access the raw methods on } // OwnableUpgradeableCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract. type OwnableUpgradeableCallerRaw struct { Contract *OwnableUpgradeableCaller // Generic read-only contract binding to access the raw methods on } // OwnableUpgradeableTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract. type OwnableUpgradeableTransactorRaw struct { Contract *OwnableUpgradeableTransactor // Generic write-only contract binding to access the raw methods on } // NewOwnableUpgradeable creates a new instance of OwnableUpgradeable, bound to a specific deployed contract. func NewOwnableUpgradeable(address common.Address, backend bind.ContractBackend) (*OwnableUpgradeable, error) { contract, err := bindOwnableUpgradeable(address, backend, backend, backend) if err != nil { return nil, err } return &OwnableUpgradeable{OwnableUpgradeableCaller: OwnableUpgradeableCaller{contract: contract}, OwnableUpgradeableTransactor: OwnableUpgradeableTransactor{contract: contract}, OwnableUpgradeableFilterer: OwnableUpgradeableFilterer{contract: contract}}, nil } // NewOwnableUpgradeableCaller creates a new read-only instance of OwnableUpgradeable, bound to a specific deployed contract. func NewOwnableUpgradeableCaller(address common.Address, caller bind.ContractCaller) (*OwnableUpgradeableCaller, error) { contract, err := bindOwnableUpgradeable(address, caller, nil, nil) if err != nil { return nil, err } return &OwnableUpgradeableCaller{contract: contract}, nil } // NewOwnableUpgradeableTransactor creates a new write-only instance of OwnableUpgradeable, bound to a specific deployed contract. func NewOwnableUpgradeableTransactor(address common.Address, transactor bind.ContractTransactor) (*OwnableUpgradeableTransactor, error) { contract, err := bindOwnableUpgradeable(address, nil, transactor, nil) if err != nil { return nil, err } return &OwnableUpgradeableTransactor{contract: contract}, nil } // NewOwnableUpgradeableFilterer creates a new log filterer instance of OwnableUpgradeable, bound to a specific deployed contract. func NewOwnableUpgradeableFilterer(address common.Address, filterer bind.ContractFilterer) (*OwnableUpgradeableFilterer, error) { contract, err := bindOwnableUpgradeable(address, nil, nil, filterer) if err != nil { return nil, err } return &OwnableUpgradeableFilterer{contract: contract}, nil } // bindOwnableUpgradeable binds a generic wrapper to an already deployed contract. func bindOwnableUpgradeable(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { parsed, err := OwnableUpgradeableMetaData.GetAbi() 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 (_OwnableUpgradeable *OwnableUpgradeableRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { return _OwnableUpgradeable.Contract.OwnableUpgradeableCaller.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 (_OwnableUpgradeable *OwnableUpgradeableRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { return _OwnableUpgradeable.Contract.OwnableUpgradeableTransactor.contract.Transfer(opts) } // Transact invokes the (paid) contract method with params as input values. func (_OwnableUpgradeable *OwnableUpgradeableRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { return _OwnableUpgradeable.Contract.OwnableUpgradeableTransactor.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 (_OwnableUpgradeable *OwnableUpgradeableCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { return _OwnableUpgradeable.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 (_OwnableUpgradeable *OwnableUpgradeableTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { return _OwnableUpgradeable.Contract.contract.Transfer(opts) } // Transact invokes the (paid) contract method with params as input values. func (_OwnableUpgradeable *OwnableUpgradeableTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { return _OwnableUpgradeable.Contract.contract.Transact(opts, method, params...) } // Owner is a free data retrieval call binding the contract method 0x8da5cb5b. // // Solidity: function owner() view returns(address) func (_OwnableUpgradeable *OwnableUpgradeableCaller) Owner(opts *bind.CallOpts) (common.Address, error) { var out []interface{} err := _OwnableUpgradeable.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 (_OwnableUpgradeable *OwnableUpgradeableSession) Owner() (common.Address, error) { return _OwnableUpgradeable.Contract.Owner(&_OwnableUpgradeable.CallOpts) } // Owner is a free data retrieval call binding the contract method 0x8da5cb5b. // // Solidity: function owner() view returns(address) func (_OwnableUpgradeable *OwnableUpgradeableCallerSession) Owner() (common.Address, error) { return _OwnableUpgradeable.Contract.Owner(&_OwnableUpgradeable.CallOpts) } // RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6. // // Solidity: function renounceOwnership() returns() func (_OwnableUpgradeable *OwnableUpgradeableTransactor) RenounceOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { return _OwnableUpgradeable.contract.Transact(opts, "renounceOwnership") } // RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6. // // Solidity: function renounceOwnership() returns() func (_OwnableUpgradeable *OwnableUpgradeableSession) RenounceOwnership() (*types.Transaction, error) { return _OwnableUpgradeable.Contract.RenounceOwnership(&_OwnableUpgradeable.TransactOpts) } // RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6. // // Solidity: function renounceOwnership() returns() func (_OwnableUpgradeable *OwnableUpgradeableTransactorSession) RenounceOwnership() (*types.Transaction, error) { return _OwnableUpgradeable.Contract.RenounceOwnership(&_OwnableUpgradeable.TransactOpts) } // TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b. // // Solidity: function transferOwnership(address newOwner) returns() func (_OwnableUpgradeable *OwnableUpgradeableTransactor) TransferOwnership(opts *bind.TransactOpts, newOwner common.Address) (*types.Transaction, error) { return _OwnableUpgradeable.contract.Transact(opts, "transferOwnership", newOwner) } // TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b. // // Solidity: function transferOwnership(address newOwner) returns() func (_OwnableUpgradeable *OwnableUpgradeableSession) TransferOwnership(newOwner common.Address) (*types.Transaction, error) { return _OwnableUpgradeable.Contract.TransferOwnership(&_OwnableUpgradeable.TransactOpts, newOwner) } // TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b. // // Solidity: function transferOwnership(address newOwner) returns() func (_OwnableUpgradeable *OwnableUpgradeableTransactorSession) TransferOwnership(newOwner common.Address) (*types.Transaction, error) { return _OwnableUpgradeable.Contract.TransferOwnership(&_OwnableUpgradeable.TransactOpts, newOwner) } // OwnableUpgradeableInitializedIterator is returned from FilterInitialized and is used to iterate over the raw logs and unpacked data for Initialized events raised by the OwnableUpgradeable contract. type OwnableUpgradeableInitializedIterator struct { Event *OwnableUpgradeableInitialized // 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 *OwnableUpgradeableInitializedIterator) 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(OwnableUpgradeableInitialized) 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(OwnableUpgradeableInitialized) 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 *OwnableUpgradeableInitializedIterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. func (it *OwnableUpgradeableInitializedIterator) Close() error { it.sub.Unsubscribe() return nil } // OwnableUpgradeableInitialized represents a Initialized event raised by the OwnableUpgradeable contract. type OwnableUpgradeableInitialized struct { Version uint8 Raw types.Log // Blockchain specific contextual infos } // FilterInitialized is a free log retrieval operation binding the contract event 0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498. // // Solidity: event Initialized(uint8 version) func (_OwnableUpgradeable *OwnableUpgradeableFilterer) FilterInitialized(opts *bind.FilterOpts) (*OwnableUpgradeableInitializedIterator, error) { logs, sub, err := _OwnableUpgradeable.contract.FilterLogs(opts, "Initialized") if err != nil { return nil, err } return &OwnableUpgradeableInitializedIterator{contract: _OwnableUpgradeable.contract, event: "Initialized", logs: logs, sub: sub}, nil } // WatchInitialized is a free log subscription operation binding the contract event 0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498. // // Solidity: event Initialized(uint8 version) func (_OwnableUpgradeable *OwnableUpgradeableFilterer) WatchInitialized(opts *bind.WatchOpts, sink chan<- *OwnableUpgradeableInitialized) (event.Subscription, error) { logs, sub, err := _OwnableUpgradeable.contract.WatchLogs(opts, "Initialized") 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(OwnableUpgradeableInitialized) if err := _OwnableUpgradeable.contract.UnpackLog(event, "Initialized", 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 } // ParseInitialized is a log parse operation binding the contract event 0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498. // // Solidity: event Initialized(uint8 version) func (_OwnableUpgradeable *OwnableUpgradeableFilterer) ParseInitialized(log types.Log) (*OwnableUpgradeableInitialized, error) { event := new(OwnableUpgradeableInitialized) if err := _OwnableUpgradeable.contract.UnpackLog(event, "Initialized", log); err != nil { return nil, err } event.Raw = log return event, nil } // OwnableUpgradeableOwnershipTransferredIterator is returned from FilterOwnershipTransferred and is used to iterate over the raw logs and unpacked data for OwnershipTransferred events raised by the OwnableUpgradeable contract. type OwnableUpgradeableOwnershipTransferredIterator struct { Event *OwnableUpgradeableOwnershipTransferred // 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 *OwnableUpgradeableOwnershipTransferredIterator) 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(OwnableUpgradeableOwnershipTransferred) 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(OwnableUpgradeableOwnershipTransferred) 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 *OwnableUpgradeableOwnershipTransferredIterator) Error() error { return it.fail } // Close terminates the iteration process, releasing any pending underlying // resources. func (it *OwnableUpgradeableOwnershipTransferredIterator) Close() error { it.sub.Unsubscribe() return nil } // OwnableUpgradeableOwnershipTransferred represents a OwnershipTransferred event raised by the OwnableUpgradeable contract. type OwnableUpgradeableOwnershipTransferred 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 (_OwnableUpgradeable *OwnableUpgradeableFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, previousOwner []common.Address, newOwner []common.Address) (*OwnableUpgradeableOwnershipTransferredIterator, 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 := _OwnableUpgradeable.contract.FilterLogs(opts, "OwnershipTransferred", previousOwnerRule, newOwnerRule) if err != nil { return nil, err } return &OwnableUpgradeableOwnershipTransferredIterator{contract: _OwnableUpgradeable.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 (_OwnableUpgradeable *OwnableUpgradeableFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *OwnableUpgradeableOwnershipTransferred, 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 := _OwnableUpgradeable.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(OwnableUpgradeableOwnershipTransferred) if err := _OwnableUpgradeable.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 (_OwnableUpgradeable *OwnableUpgradeableFilterer) ParseOwnershipTransferred(log types.Log) (*OwnableUpgradeableOwnershipTransferred, error) { event := new(OwnableUpgradeableOwnershipTransferred) if err := _OwnableUpgradeable.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { return nil, err } event.Raw = log return event, nil }