github.com/0xPolygon/supernets2-node@v0.0.0-20230711153321-2fe574524eaa/etherman/smartcontracts/polygonzkevmglobalexitroot/polygonzkevmglobalexitroot.go (about)

     1  // Code generated - DO NOT EDIT.
     2  // This file is a generated binding and any manual changes will be lost.
     3  
     4  package polygonzkevmglobalexitroot
     5  
     6  import (
     7  	"errors"
     8  	"math/big"
     9  	"strings"
    10  
    11  	ethereum "github.com/ethereum/go-ethereum"
    12  	"github.com/ethereum/go-ethereum/accounts/abi"
    13  	"github.com/ethereum/go-ethereum/accounts/abi/bind"
    14  	"github.com/ethereum/go-ethereum/common"
    15  	"github.com/ethereum/go-ethereum/core/types"
    16  	"github.com/ethereum/go-ethereum/event"
    17  )
    18  
    19  // Reference imports to suppress errors if they are not otherwise used.
    20  var (
    21  	_ = errors.New
    22  	_ = big.NewInt
    23  	_ = strings.NewReader
    24  	_ = ethereum.NotFound
    25  	_ = bind.Bind
    26  	_ = common.Big1
    27  	_ = types.BloomLookup
    28  	_ = event.NewSubscription
    29  	_ = abi.ConvertType
    30  )
    31  
    32  // PolygonzkevmglobalexitrootMetaData contains all meta data concerning the Polygonzkevmglobalexitroot contract.
    33  var PolygonzkevmglobalexitrootMetaData = &bind.MetaData{
    34  	ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_rollupAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_bridgeAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"OnlyAllowedContracts\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"mainnetExitRoot\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"rollupExitRoot\",\"type\":\"bytes32\"}],\"name\":\"UpdateGlobalExitRoot\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"bridgeAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLastGlobalExitRoot\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"globalExitRootMap\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"lastMainnetExitRoot\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"lastRollupExitRoot\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"rollupAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"newRoot\",\"type\":\"bytes32\"}],\"name\":\"updateExitRoot\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]",
    35  	Bin: "0x60c060405234801561001057600080fd5b506040516103f83803806103f883398101604081905261002f91610062565b6001600160a01b0391821660a05216608052610095565b80516001600160a01b038116811461005d57600080fd5b919050565b6000806040838503121561007557600080fd5b61007e83610046565b915061008c60208401610046565b90509250929050565b60805160a0516103316100c76000396000818160e901526101bd015260008181610135015261017401526103316000f3fe608060405234801561001057600080fd5b506004361061007d5760003560e01c806333d6247d1161005b57806333d6247d146100c75780633ed691ef146100dc5780635ec6a8df146100e4578063a3c573eb1461013057600080fd5b806301fd904414610082578063257b36321461009e578063319cf735146100be575b600080fd5b61008b60005481565b6040519081526020015b60405180910390f35b61008b6100ac3660046102e2565b60026020526000908152604090205481565b61008b60015481565b6100da6100d53660046102e2565b610157565b005b61008b6102a6565b61010b7f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610095565b61010b7f000000000000000000000000000000000000000000000000000000000000000081565b60005460015473ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001633036101a65750600182905581610222565b73ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001633036101f0576000839055829150610222565b6040517fb49365dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60408051602080820184905281830185905282518083038401815260609092019092528051910120600090600081815260026020526040812054919250036102a05760008181526002602052604080822042905551849184917f61014378f82a0d809aefaf87a8ac9505b89c321808287a6e7810f29304c1fce39190a35b50505050565b60006102dd600154600054604080516020808201949094528082019290925280518083038201815260609092019052805191012090565b905090565b6000602082840312156102f457600080fd5b503591905056fea2646970667358221220bc23c6d5d3992802bdfd06ef45362230dcda7d33db81b1dc3ef40d86219e81c864736f6c63430008110033",
    36  }
    37  
    38  // PolygonzkevmglobalexitrootABI is the input ABI used to generate the binding from.
    39  // Deprecated: Use PolygonzkevmglobalexitrootMetaData.ABI instead.
    40  var PolygonzkevmglobalexitrootABI = PolygonzkevmglobalexitrootMetaData.ABI
    41  
    42  // PolygonzkevmglobalexitrootBin is the compiled bytecode used for deploying new contracts.
    43  // Deprecated: Use PolygonzkevmglobalexitrootMetaData.Bin instead.
    44  var PolygonzkevmglobalexitrootBin = PolygonzkevmglobalexitrootMetaData.Bin
    45  
    46  // DeployPolygonzkevmglobalexitroot deploys a new Ethereum contract, binding an instance of Polygonzkevmglobalexitroot to it.
    47  func DeployPolygonzkevmglobalexitroot(auth *bind.TransactOpts, backend bind.ContractBackend, _rollupAddress common.Address, _bridgeAddress common.Address) (common.Address, *types.Transaction, *Polygonzkevmglobalexitroot, error) {
    48  	parsed, err := PolygonzkevmglobalexitrootMetaData.GetAbi()
    49  	if err != nil {
    50  		return common.Address{}, nil, nil, err
    51  	}
    52  	if parsed == nil {
    53  		return common.Address{}, nil, nil, errors.New("GetABI returned nil")
    54  	}
    55  
    56  	address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(PolygonzkevmglobalexitrootBin), backend, _rollupAddress, _bridgeAddress)
    57  	if err != nil {
    58  		return common.Address{}, nil, nil, err
    59  	}
    60  	return address, tx, &Polygonzkevmglobalexitroot{PolygonzkevmglobalexitrootCaller: PolygonzkevmglobalexitrootCaller{contract: contract}, PolygonzkevmglobalexitrootTransactor: PolygonzkevmglobalexitrootTransactor{contract: contract}, PolygonzkevmglobalexitrootFilterer: PolygonzkevmglobalexitrootFilterer{contract: contract}}, nil
    61  }
    62  
    63  // Polygonzkevmglobalexitroot is an auto generated Go binding around an Ethereum contract.
    64  type Polygonzkevmglobalexitroot struct {
    65  	PolygonzkevmglobalexitrootCaller     // Read-only binding to the contract
    66  	PolygonzkevmglobalexitrootTransactor // Write-only binding to the contract
    67  	PolygonzkevmglobalexitrootFilterer   // Log filterer for contract events
    68  }
    69  
    70  // PolygonzkevmglobalexitrootCaller is an auto generated read-only Go binding around an Ethereum contract.
    71  type PolygonzkevmglobalexitrootCaller struct {
    72  	contract *bind.BoundContract // Generic contract wrapper for the low level calls
    73  }
    74  
    75  // PolygonzkevmglobalexitrootTransactor is an auto generated write-only Go binding around an Ethereum contract.
    76  type PolygonzkevmglobalexitrootTransactor struct {
    77  	contract *bind.BoundContract // Generic contract wrapper for the low level calls
    78  }
    79  
    80  // PolygonzkevmglobalexitrootFilterer is an auto generated log filtering Go binding around an Ethereum contract events.
    81  type PolygonzkevmglobalexitrootFilterer struct {
    82  	contract *bind.BoundContract // Generic contract wrapper for the low level calls
    83  }
    84  
    85  // PolygonzkevmglobalexitrootSession is an auto generated Go binding around an Ethereum contract,
    86  // with pre-set call and transact options.
    87  type PolygonzkevmglobalexitrootSession struct {
    88  	Contract     *Polygonzkevmglobalexitroot // Generic contract binding to set the session for
    89  	CallOpts     bind.CallOpts               // Call options to use throughout this session
    90  	TransactOpts bind.TransactOpts           // Transaction auth options to use throughout this session
    91  }
    92  
    93  // PolygonzkevmglobalexitrootCallerSession is an auto generated read-only Go binding around an Ethereum contract,
    94  // with pre-set call options.
    95  type PolygonzkevmglobalexitrootCallerSession struct {
    96  	Contract *PolygonzkevmglobalexitrootCaller // Generic contract caller binding to set the session for
    97  	CallOpts bind.CallOpts                     // Call options to use throughout this session
    98  }
    99  
   100  // PolygonzkevmglobalexitrootTransactorSession is an auto generated write-only Go binding around an Ethereum contract,
   101  // with pre-set transact options.
   102  type PolygonzkevmglobalexitrootTransactorSession struct {
   103  	Contract     *PolygonzkevmglobalexitrootTransactor // Generic contract transactor binding to set the session for
   104  	TransactOpts bind.TransactOpts                     // Transaction auth options to use throughout this session
   105  }
   106  
   107  // PolygonzkevmglobalexitrootRaw is an auto generated low-level Go binding around an Ethereum contract.
   108  type PolygonzkevmglobalexitrootRaw struct {
   109  	Contract *Polygonzkevmglobalexitroot // Generic contract binding to access the raw methods on
   110  }
   111  
   112  // PolygonzkevmglobalexitrootCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract.
   113  type PolygonzkevmglobalexitrootCallerRaw struct {
   114  	Contract *PolygonzkevmglobalexitrootCaller // Generic read-only contract binding to access the raw methods on
   115  }
   116  
   117  // PolygonzkevmglobalexitrootTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract.
   118  type PolygonzkevmglobalexitrootTransactorRaw struct {
   119  	Contract *PolygonzkevmglobalexitrootTransactor // Generic write-only contract binding to access the raw methods on
   120  }
   121  
   122  // NewPolygonzkevmglobalexitroot creates a new instance of Polygonzkevmglobalexitroot, bound to a specific deployed contract.
   123  func NewPolygonzkevmglobalexitroot(address common.Address, backend bind.ContractBackend) (*Polygonzkevmglobalexitroot, error) {
   124  	contract, err := bindPolygonzkevmglobalexitroot(address, backend, backend, backend)
   125  	if err != nil {
   126  		return nil, err
   127  	}
   128  	return &Polygonzkevmglobalexitroot{PolygonzkevmglobalexitrootCaller: PolygonzkevmglobalexitrootCaller{contract: contract}, PolygonzkevmglobalexitrootTransactor: PolygonzkevmglobalexitrootTransactor{contract: contract}, PolygonzkevmglobalexitrootFilterer: PolygonzkevmglobalexitrootFilterer{contract: contract}}, nil
   129  }
   130  
   131  // NewPolygonzkevmglobalexitrootCaller creates a new read-only instance of Polygonzkevmglobalexitroot, bound to a specific deployed contract.
   132  func NewPolygonzkevmglobalexitrootCaller(address common.Address, caller bind.ContractCaller) (*PolygonzkevmglobalexitrootCaller, error) {
   133  	contract, err := bindPolygonzkevmglobalexitroot(address, caller, nil, nil)
   134  	if err != nil {
   135  		return nil, err
   136  	}
   137  	return &PolygonzkevmglobalexitrootCaller{contract: contract}, nil
   138  }
   139  
   140  // NewPolygonzkevmglobalexitrootTransactor creates a new write-only instance of Polygonzkevmglobalexitroot, bound to a specific deployed contract.
   141  func NewPolygonzkevmglobalexitrootTransactor(address common.Address, transactor bind.ContractTransactor) (*PolygonzkevmglobalexitrootTransactor, error) {
   142  	contract, err := bindPolygonzkevmglobalexitroot(address, nil, transactor, nil)
   143  	if err != nil {
   144  		return nil, err
   145  	}
   146  	return &PolygonzkevmglobalexitrootTransactor{contract: contract}, nil
   147  }
   148  
   149  // NewPolygonzkevmglobalexitrootFilterer creates a new log filterer instance of Polygonzkevmglobalexitroot, bound to a specific deployed contract.
   150  func NewPolygonzkevmglobalexitrootFilterer(address common.Address, filterer bind.ContractFilterer) (*PolygonzkevmglobalexitrootFilterer, error) {
   151  	contract, err := bindPolygonzkevmglobalexitroot(address, nil, nil, filterer)
   152  	if err != nil {
   153  		return nil, err
   154  	}
   155  	return &PolygonzkevmglobalexitrootFilterer{contract: contract}, nil
   156  }
   157  
   158  // bindPolygonzkevmglobalexitroot binds a generic wrapper to an already deployed contract.
   159  func bindPolygonzkevmglobalexitroot(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) {
   160  	parsed, err := PolygonzkevmglobalexitrootMetaData.GetAbi()
   161  	if err != nil {
   162  		return nil, err
   163  	}
   164  	return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil
   165  }
   166  
   167  // Call invokes the (constant) contract method with params as input values and
   168  // sets the output to result. The result type might be a single field for simple
   169  // returns, a slice of interfaces for anonymous returns and a struct for named
   170  // returns.
   171  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error {
   172  	return _Polygonzkevmglobalexitroot.Contract.PolygonzkevmglobalexitrootCaller.contract.Call(opts, result, method, params...)
   173  }
   174  
   175  // Transfer initiates a plain transaction to move funds to the contract, calling
   176  // its default method if one is available.
   177  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) {
   178  	return _Polygonzkevmglobalexitroot.Contract.PolygonzkevmglobalexitrootTransactor.contract.Transfer(opts)
   179  }
   180  
   181  // Transact invokes the (paid) contract method with params as input values.
   182  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) {
   183  	return _Polygonzkevmglobalexitroot.Contract.PolygonzkevmglobalexitrootTransactor.contract.Transact(opts, method, params...)
   184  }
   185  
   186  // Call invokes the (constant) contract method with params as input values and
   187  // sets the output to result. The result type might be a single field for simple
   188  // returns, a slice of interfaces for anonymous returns and a struct for named
   189  // returns.
   190  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error {
   191  	return _Polygonzkevmglobalexitroot.Contract.contract.Call(opts, result, method, params...)
   192  }
   193  
   194  // Transfer initiates a plain transaction to move funds to the contract, calling
   195  // its default method if one is available.
   196  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) {
   197  	return _Polygonzkevmglobalexitroot.Contract.contract.Transfer(opts)
   198  }
   199  
   200  // Transact invokes the (paid) contract method with params as input values.
   201  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) {
   202  	return _Polygonzkevmglobalexitroot.Contract.contract.Transact(opts, method, params...)
   203  }
   204  
   205  // BridgeAddress is a free data retrieval call binding the contract method 0xa3c573eb.
   206  //
   207  // Solidity: function bridgeAddress() view returns(address)
   208  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootCaller) BridgeAddress(opts *bind.CallOpts) (common.Address, error) {
   209  	var out []interface{}
   210  	err := _Polygonzkevmglobalexitroot.contract.Call(opts, &out, "bridgeAddress")
   211  
   212  	if err != nil {
   213  		return *new(common.Address), err
   214  	}
   215  
   216  	out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
   217  
   218  	return out0, err
   219  
   220  }
   221  
   222  // BridgeAddress is a free data retrieval call binding the contract method 0xa3c573eb.
   223  //
   224  // Solidity: function bridgeAddress() view returns(address)
   225  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootSession) BridgeAddress() (common.Address, error) {
   226  	return _Polygonzkevmglobalexitroot.Contract.BridgeAddress(&_Polygonzkevmglobalexitroot.CallOpts)
   227  }
   228  
   229  // BridgeAddress is a free data retrieval call binding the contract method 0xa3c573eb.
   230  //
   231  // Solidity: function bridgeAddress() view returns(address)
   232  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootCallerSession) BridgeAddress() (common.Address, error) {
   233  	return _Polygonzkevmglobalexitroot.Contract.BridgeAddress(&_Polygonzkevmglobalexitroot.CallOpts)
   234  }
   235  
   236  // GetLastGlobalExitRoot is a free data retrieval call binding the contract method 0x3ed691ef.
   237  //
   238  // Solidity: function getLastGlobalExitRoot() view returns(bytes32)
   239  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootCaller) GetLastGlobalExitRoot(opts *bind.CallOpts) ([32]byte, error) {
   240  	var out []interface{}
   241  	err := _Polygonzkevmglobalexitroot.contract.Call(opts, &out, "getLastGlobalExitRoot")
   242  
   243  	if err != nil {
   244  		return *new([32]byte), err
   245  	}
   246  
   247  	out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte)
   248  
   249  	return out0, err
   250  
   251  }
   252  
   253  // GetLastGlobalExitRoot is a free data retrieval call binding the contract method 0x3ed691ef.
   254  //
   255  // Solidity: function getLastGlobalExitRoot() view returns(bytes32)
   256  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootSession) GetLastGlobalExitRoot() ([32]byte, error) {
   257  	return _Polygonzkevmglobalexitroot.Contract.GetLastGlobalExitRoot(&_Polygonzkevmglobalexitroot.CallOpts)
   258  }
   259  
   260  // GetLastGlobalExitRoot is a free data retrieval call binding the contract method 0x3ed691ef.
   261  //
   262  // Solidity: function getLastGlobalExitRoot() view returns(bytes32)
   263  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootCallerSession) GetLastGlobalExitRoot() ([32]byte, error) {
   264  	return _Polygonzkevmglobalexitroot.Contract.GetLastGlobalExitRoot(&_Polygonzkevmglobalexitroot.CallOpts)
   265  }
   266  
   267  // GlobalExitRootMap is a free data retrieval call binding the contract method 0x257b3632.
   268  //
   269  // Solidity: function globalExitRootMap(bytes32 ) view returns(uint256)
   270  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootCaller) GlobalExitRootMap(opts *bind.CallOpts, arg0 [32]byte) (*big.Int, error) {
   271  	var out []interface{}
   272  	err := _Polygonzkevmglobalexitroot.contract.Call(opts, &out, "globalExitRootMap", arg0)
   273  
   274  	if err != nil {
   275  		return *new(*big.Int), err
   276  	}
   277  
   278  	out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int)
   279  
   280  	return out0, err
   281  
   282  }
   283  
   284  // GlobalExitRootMap is a free data retrieval call binding the contract method 0x257b3632.
   285  //
   286  // Solidity: function globalExitRootMap(bytes32 ) view returns(uint256)
   287  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootSession) GlobalExitRootMap(arg0 [32]byte) (*big.Int, error) {
   288  	return _Polygonzkevmglobalexitroot.Contract.GlobalExitRootMap(&_Polygonzkevmglobalexitroot.CallOpts, arg0)
   289  }
   290  
   291  // GlobalExitRootMap is a free data retrieval call binding the contract method 0x257b3632.
   292  //
   293  // Solidity: function globalExitRootMap(bytes32 ) view returns(uint256)
   294  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootCallerSession) GlobalExitRootMap(arg0 [32]byte) (*big.Int, error) {
   295  	return _Polygonzkevmglobalexitroot.Contract.GlobalExitRootMap(&_Polygonzkevmglobalexitroot.CallOpts, arg0)
   296  }
   297  
   298  // LastMainnetExitRoot is a free data retrieval call binding the contract method 0x319cf735.
   299  //
   300  // Solidity: function lastMainnetExitRoot() view returns(bytes32)
   301  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootCaller) LastMainnetExitRoot(opts *bind.CallOpts) ([32]byte, error) {
   302  	var out []interface{}
   303  	err := _Polygonzkevmglobalexitroot.contract.Call(opts, &out, "lastMainnetExitRoot")
   304  
   305  	if err != nil {
   306  		return *new([32]byte), err
   307  	}
   308  
   309  	out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte)
   310  
   311  	return out0, err
   312  
   313  }
   314  
   315  // LastMainnetExitRoot is a free data retrieval call binding the contract method 0x319cf735.
   316  //
   317  // Solidity: function lastMainnetExitRoot() view returns(bytes32)
   318  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootSession) LastMainnetExitRoot() ([32]byte, error) {
   319  	return _Polygonzkevmglobalexitroot.Contract.LastMainnetExitRoot(&_Polygonzkevmglobalexitroot.CallOpts)
   320  }
   321  
   322  // LastMainnetExitRoot is a free data retrieval call binding the contract method 0x319cf735.
   323  //
   324  // Solidity: function lastMainnetExitRoot() view returns(bytes32)
   325  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootCallerSession) LastMainnetExitRoot() ([32]byte, error) {
   326  	return _Polygonzkevmglobalexitroot.Contract.LastMainnetExitRoot(&_Polygonzkevmglobalexitroot.CallOpts)
   327  }
   328  
   329  // LastRollupExitRoot is a free data retrieval call binding the contract method 0x01fd9044.
   330  //
   331  // Solidity: function lastRollupExitRoot() view returns(bytes32)
   332  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootCaller) LastRollupExitRoot(opts *bind.CallOpts) ([32]byte, error) {
   333  	var out []interface{}
   334  	err := _Polygonzkevmglobalexitroot.contract.Call(opts, &out, "lastRollupExitRoot")
   335  
   336  	if err != nil {
   337  		return *new([32]byte), err
   338  	}
   339  
   340  	out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte)
   341  
   342  	return out0, err
   343  
   344  }
   345  
   346  // LastRollupExitRoot is a free data retrieval call binding the contract method 0x01fd9044.
   347  //
   348  // Solidity: function lastRollupExitRoot() view returns(bytes32)
   349  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootSession) LastRollupExitRoot() ([32]byte, error) {
   350  	return _Polygonzkevmglobalexitroot.Contract.LastRollupExitRoot(&_Polygonzkevmglobalexitroot.CallOpts)
   351  }
   352  
   353  // LastRollupExitRoot is a free data retrieval call binding the contract method 0x01fd9044.
   354  //
   355  // Solidity: function lastRollupExitRoot() view returns(bytes32)
   356  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootCallerSession) LastRollupExitRoot() ([32]byte, error) {
   357  	return _Polygonzkevmglobalexitroot.Contract.LastRollupExitRoot(&_Polygonzkevmglobalexitroot.CallOpts)
   358  }
   359  
   360  // RollupAddress is a free data retrieval call binding the contract method 0x5ec6a8df.
   361  //
   362  // Solidity: function rollupAddress() view returns(address)
   363  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootCaller) RollupAddress(opts *bind.CallOpts) (common.Address, error) {
   364  	var out []interface{}
   365  	err := _Polygonzkevmglobalexitroot.contract.Call(opts, &out, "rollupAddress")
   366  
   367  	if err != nil {
   368  		return *new(common.Address), err
   369  	}
   370  
   371  	out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
   372  
   373  	return out0, err
   374  
   375  }
   376  
   377  // RollupAddress is a free data retrieval call binding the contract method 0x5ec6a8df.
   378  //
   379  // Solidity: function rollupAddress() view returns(address)
   380  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootSession) RollupAddress() (common.Address, error) {
   381  	return _Polygonzkevmglobalexitroot.Contract.RollupAddress(&_Polygonzkevmglobalexitroot.CallOpts)
   382  }
   383  
   384  // RollupAddress is a free data retrieval call binding the contract method 0x5ec6a8df.
   385  //
   386  // Solidity: function rollupAddress() view returns(address)
   387  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootCallerSession) RollupAddress() (common.Address, error) {
   388  	return _Polygonzkevmglobalexitroot.Contract.RollupAddress(&_Polygonzkevmglobalexitroot.CallOpts)
   389  }
   390  
   391  // UpdateExitRoot is a paid mutator transaction binding the contract method 0x33d6247d.
   392  //
   393  // Solidity: function updateExitRoot(bytes32 newRoot) returns()
   394  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootTransactor) UpdateExitRoot(opts *bind.TransactOpts, newRoot [32]byte) (*types.Transaction, error) {
   395  	return _Polygonzkevmglobalexitroot.contract.Transact(opts, "updateExitRoot", newRoot)
   396  }
   397  
   398  // UpdateExitRoot is a paid mutator transaction binding the contract method 0x33d6247d.
   399  //
   400  // Solidity: function updateExitRoot(bytes32 newRoot) returns()
   401  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootSession) UpdateExitRoot(newRoot [32]byte) (*types.Transaction, error) {
   402  	return _Polygonzkevmglobalexitroot.Contract.UpdateExitRoot(&_Polygonzkevmglobalexitroot.TransactOpts, newRoot)
   403  }
   404  
   405  // UpdateExitRoot is a paid mutator transaction binding the contract method 0x33d6247d.
   406  //
   407  // Solidity: function updateExitRoot(bytes32 newRoot) returns()
   408  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootTransactorSession) UpdateExitRoot(newRoot [32]byte) (*types.Transaction, error) {
   409  	return _Polygonzkevmglobalexitroot.Contract.UpdateExitRoot(&_Polygonzkevmglobalexitroot.TransactOpts, newRoot)
   410  }
   411  
   412  // PolygonzkevmglobalexitrootUpdateGlobalExitRootIterator is returned from FilterUpdateGlobalExitRoot and is used to iterate over the raw logs and unpacked data for UpdateGlobalExitRoot events raised by the Polygonzkevmglobalexitroot contract.
   413  type PolygonzkevmglobalexitrootUpdateGlobalExitRootIterator struct {
   414  	Event *PolygonzkevmglobalexitrootUpdateGlobalExitRoot // Event containing the contract specifics and raw log
   415  
   416  	contract *bind.BoundContract // Generic contract to use for unpacking event data
   417  	event    string              // Event name to use for unpacking event data
   418  
   419  	logs chan types.Log        // Log channel receiving the found contract events
   420  	sub  ethereum.Subscription // Subscription for errors, completion and termination
   421  	done bool                  // Whether the subscription completed delivering logs
   422  	fail error                 // Occurred error to stop iteration
   423  }
   424  
   425  // Next advances the iterator to the subsequent event, returning whether there
   426  // are any more events found. In case of a retrieval or parsing error, false is
   427  // returned and Error() can be queried for the exact failure.
   428  func (it *PolygonzkevmglobalexitrootUpdateGlobalExitRootIterator) Next() bool {
   429  	// If the iterator failed, stop iterating
   430  	if it.fail != nil {
   431  		return false
   432  	}
   433  	// If the iterator completed, deliver directly whatever's available
   434  	if it.done {
   435  		select {
   436  		case log := <-it.logs:
   437  			it.Event = new(PolygonzkevmglobalexitrootUpdateGlobalExitRoot)
   438  			if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
   439  				it.fail = err
   440  				return false
   441  			}
   442  			it.Event.Raw = log
   443  			return true
   444  
   445  		default:
   446  			return false
   447  		}
   448  	}
   449  	// Iterator still in progress, wait for either a data or an error event
   450  	select {
   451  	case log := <-it.logs:
   452  		it.Event = new(PolygonzkevmglobalexitrootUpdateGlobalExitRoot)
   453  		if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
   454  			it.fail = err
   455  			return false
   456  		}
   457  		it.Event.Raw = log
   458  		return true
   459  
   460  	case err := <-it.sub.Err():
   461  		it.done = true
   462  		it.fail = err
   463  		return it.Next()
   464  	}
   465  }
   466  
   467  // Error returns any retrieval or parsing error occurred during filtering.
   468  func (it *PolygonzkevmglobalexitrootUpdateGlobalExitRootIterator) Error() error {
   469  	return it.fail
   470  }
   471  
   472  // Close terminates the iteration process, releasing any pending underlying
   473  // resources.
   474  func (it *PolygonzkevmglobalexitrootUpdateGlobalExitRootIterator) Close() error {
   475  	it.sub.Unsubscribe()
   476  	return nil
   477  }
   478  
   479  // PolygonzkevmglobalexitrootUpdateGlobalExitRoot represents a UpdateGlobalExitRoot event raised by the Polygonzkevmglobalexitroot contract.
   480  type PolygonzkevmglobalexitrootUpdateGlobalExitRoot struct {
   481  	MainnetExitRoot [32]byte
   482  	RollupExitRoot  [32]byte
   483  	Raw             types.Log // Blockchain specific contextual infos
   484  }
   485  
   486  // FilterUpdateGlobalExitRoot is a free log retrieval operation binding the contract event 0x61014378f82a0d809aefaf87a8ac9505b89c321808287a6e7810f29304c1fce3.
   487  //
   488  // Solidity: event UpdateGlobalExitRoot(bytes32 indexed mainnetExitRoot, bytes32 indexed rollupExitRoot)
   489  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootFilterer) FilterUpdateGlobalExitRoot(opts *bind.FilterOpts, mainnetExitRoot [][32]byte, rollupExitRoot [][32]byte) (*PolygonzkevmglobalexitrootUpdateGlobalExitRootIterator, error) {
   490  
   491  	var mainnetExitRootRule []interface{}
   492  	for _, mainnetExitRootItem := range mainnetExitRoot {
   493  		mainnetExitRootRule = append(mainnetExitRootRule, mainnetExitRootItem)
   494  	}
   495  	var rollupExitRootRule []interface{}
   496  	for _, rollupExitRootItem := range rollupExitRoot {
   497  		rollupExitRootRule = append(rollupExitRootRule, rollupExitRootItem)
   498  	}
   499  
   500  	logs, sub, err := _Polygonzkevmglobalexitroot.contract.FilterLogs(opts, "UpdateGlobalExitRoot", mainnetExitRootRule, rollupExitRootRule)
   501  	if err != nil {
   502  		return nil, err
   503  	}
   504  	return &PolygonzkevmglobalexitrootUpdateGlobalExitRootIterator{contract: _Polygonzkevmglobalexitroot.contract, event: "UpdateGlobalExitRoot", logs: logs, sub: sub}, nil
   505  }
   506  
   507  // WatchUpdateGlobalExitRoot is a free log subscription operation binding the contract event 0x61014378f82a0d809aefaf87a8ac9505b89c321808287a6e7810f29304c1fce3.
   508  //
   509  // Solidity: event UpdateGlobalExitRoot(bytes32 indexed mainnetExitRoot, bytes32 indexed rollupExitRoot)
   510  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootFilterer) WatchUpdateGlobalExitRoot(opts *bind.WatchOpts, sink chan<- *PolygonzkevmglobalexitrootUpdateGlobalExitRoot, mainnetExitRoot [][32]byte, rollupExitRoot [][32]byte) (event.Subscription, error) {
   511  
   512  	var mainnetExitRootRule []interface{}
   513  	for _, mainnetExitRootItem := range mainnetExitRoot {
   514  		mainnetExitRootRule = append(mainnetExitRootRule, mainnetExitRootItem)
   515  	}
   516  	var rollupExitRootRule []interface{}
   517  	for _, rollupExitRootItem := range rollupExitRoot {
   518  		rollupExitRootRule = append(rollupExitRootRule, rollupExitRootItem)
   519  	}
   520  
   521  	logs, sub, err := _Polygonzkevmglobalexitroot.contract.WatchLogs(opts, "UpdateGlobalExitRoot", mainnetExitRootRule, rollupExitRootRule)
   522  	if err != nil {
   523  		return nil, err
   524  	}
   525  	return event.NewSubscription(func(quit <-chan struct{}) error {
   526  		defer sub.Unsubscribe()
   527  		for {
   528  			select {
   529  			case log := <-logs:
   530  				// New log arrived, parse the event and forward to the user
   531  				event := new(PolygonzkevmglobalexitrootUpdateGlobalExitRoot)
   532  				if err := _Polygonzkevmglobalexitroot.contract.UnpackLog(event, "UpdateGlobalExitRoot", log); err != nil {
   533  					return err
   534  				}
   535  				event.Raw = log
   536  
   537  				select {
   538  				case sink <- event:
   539  				case err := <-sub.Err():
   540  					return err
   541  				case <-quit:
   542  					return nil
   543  				}
   544  			case err := <-sub.Err():
   545  				return err
   546  			case <-quit:
   547  				return nil
   548  			}
   549  		}
   550  	}), nil
   551  }
   552  
   553  // ParseUpdateGlobalExitRoot is a log parse operation binding the contract event 0x61014378f82a0d809aefaf87a8ac9505b89c321808287a6e7810f29304c1fce3.
   554  //
   555  // Solidity: event UpdateGlobalExitRoot(bytes32 indexed mainnetExitRoot, bytes32 indexed rollupExitRoot)
   556  func (_Polygonzkevmglobalexitroot *PolygonzkevmglobalexitrootFilterer) ParseUpdateGlobalExitRoot(log types.Log) (*PolygonzkevmglobalexitrootUpdateGlobalExitRoot, error) {
   557  	event := new(PolygonzkevmglobalexitrootUpdateGlobalExitRoot)
   558  	if err := _Polygonzkevmglobalexitroot.contract.UnpackLog(event, "UpdateGlobalExitRoot", log); err != nil {
   559  		return nil, err
   560  	}
   561  	event.Raw = log
   562  	return event, nil
   563  }