You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1909 lines
85 KiB

  1. // Code generated - DO NOT EDIT.
  2. // This file is a generated binding and any manual changes will be lost.
  3. package WithdrawalDelayer
  4. import (
  5. "math/big"
  6. "strings"
  7. ethereum "github.com/ethereum/go-ethereum"
  8. "github.com/ethereum/go-ethereum/accounts/abi"
  9. "github.com/ethereum/go-ethereum/accounts/abi/bind"
  10. "github.com/ethereum/go-ethereum/common"
  11. "github.com/ethereum/go-ethereum/core/types"
  12. "github.com/ethereum/go-ethereum/event"
  13. )
  14. // Reference imports to suppress errors if they are not otherwise used.
  15. var (
  16. _ = big.NewInt
  17. _ = strings.NewReader
  18. _ = ethereum.NotFound
  19. _ = bind.Bind
  20. _ = common.Big1
  21. _ = types.BloomLookup
  22. _ = event.NewSubscription
  23. )
  24. // WithdrawalDelayerABI is the input ABI used to generate the binding from.
  25. const WithdrawalDelayerABI = "[{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint192\",\"name\":\"amount\",\"type\":\"uint192\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"depositTimestamp\",\"type\":\"uint64\"}],\"name\":\"Deposit\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[],\"name\":\"EmergencyModeEnabled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"who\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"EscapeHatchWithdrawal\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"initialWithdrawalDelay\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"initialHermezGovernanceAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"initialEmergencyCouncil\",\"type\":\"address\"}],\"name\":\"InitializeWithdrawalDelayerEvent\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newEmergencyCouncil\",\"type\":\"address\"}],\"name\":\"NewEmergencyCouncil\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newHermezGovernanceAddress\",\"type\":\"address\"}],\"name\":\"NewHermezGovernanceAddress\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"withdrawalDelay\",\"type\":\"uint64\"}],\"name\":\"NewWithdrawalDelay\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint192\",\"name\":\"amount\",\"type\":\"uint192\"}],\"name\":\"Withdraw\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_EMERGENCY_MODE_TIME\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_WITHDRAWAL_DELAY\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"_newWithdrawalDelay\",\"type\":\"uint64\"}],\"name\":\"changeWithdrawalDelay\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"claimEmergencyCouncil\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"claimGovernance\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_token\",\"type\":\"address\"},{\"internalType\":\"uint192\",\"name\":\"_amount\",\"type\":\"uint192\"}],\"name\":\"deposit\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"_owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_token\",\"type\":\"address\"}],\"name\":\"depositInfo\",\"outputs\":[{\"internalType\":\"uint192\",\"name\":\"\",\"type\":\"uint192\"},{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"deposits\",\"outputs\":[{\"internalType\":\"uint192\",\"name\":\"amount\",\"type\":\"uint192\"},{\"internalType\":\"uint64\",\"name\":\"depositTimestamp\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"enableEmergencyMode\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_token\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"escapeHatchWithdrawal\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getEmergencyCouncil\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getEmergencyModeStartingTime\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getHermezGovernanceAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getWithdrawalDelay\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"hermezRollupAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isEmergencyMode\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pendingEmergencyCouncil\",\"outputs\":[{\"internalType\":\"addresspayable\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pendingGovernance\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"newEmergencyCouncil\",\"type\":\"address\"}],\"name\":\"transferEmergencyCouncil\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"newGovernance\",\"type\":\"address\"}],\"name\":\"transferGovernance\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"_owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_token\",\"type\":\"address\"}],\"name\":\"withdrawal\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"_initialWithdrawalDelay\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"_initialHermezRollup\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_initialHermezGovernanceAddress\",\"type\":\"address\"},{\"internalType\":\"addresspayable\",\"name\":\"_initialEmergencyCouncil\",\"type\":\"address\"}],\"name\":\"withdrawalDelayerInitializer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]"
  26. // WithdrawalDelayer is an auto generated Go binding around an Ethereum contract.
  27. type WithdrawalDelayer struct {
  28. WithdrawalDelayerCaller // Read-only binding to the contract
  29. WithdrawalDelayerTransactor // Write-only binding to the contract
  30. WithdrawalDelayerFilterer // Log filterer for contract events
  31. }
  32. // WithdrawalDelayerCaller is an auto generated read-only Go binding around an Ethereum contract.
  33. type WithdrawalDelayerCaller struct {
  34. contract *bind.BoundContract // Generic contract wrapper for the low level calls
  35. }
  36. // WithdrawalDelayerTransactor is an auto generated write-only Go binding around an Ethereum contract.
  37. type WithdrawalDelayerTransactor struct {
  38. contract *bind.BoundContract // Generic contract wrapper for the low level calls
  39. }
  40. // WithdrawalDelayerFilterer is an auto generated log filtering Go binding around an Ethereum contract events.
  41. type WithdrawalDelayerFilterer struct {
  42. contract *bind.BoundContract // Generic contract wrapper for the low level calls
  43. }
  44. // WithdrawalDelayerSession is an auto generated Go binding around an Ethereum contract,
  45. // with pre-set call and transact options.
  46. type WithdrawalDelayerSession struct {
  47. Contract *WithdrawalDelayer // Generic contract binding to set the session for
  48. CallOpts bind.CallOpts // Call options to use throughout this session
  49. TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session
  50. }
  51. // WithdrawalDelayerCallerSession is an auto generated read-only Go binding around an Ethereum contract,
  52. // with pre-set call options.
  53. type WithdrawalDelayerCallerSession struct {
  54. Contract *WithdrawalDelayerCaller // Generic contract caller binding to set the session for
  55. CallOpts bind.CallOpts // Call options to use throughout this session
  56. }
  57. // WithdrawalDelayerTransactorSession is an auto generated write-only Go binding around an Ethereum contract,
  58. // with pre-set transact options.
  59. type WithdrawalDelayerTransactorSession struct {
  60. Contract *WithdrawalDelayerTransactor // Generic contract transactor binding to set the session for
  61. TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session
  62. }
  63. // WithdrawalDelayerRaw is an auto generated low-level Go binding around an Ethereum contract.
  64. type WithdrawalDelayerRaw struct {
  65. Contract *WithdrawalDelayer // Generic contract binding to access the raw methods on
  66. }
  67. // WithdrawalDelayerCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract.
  68. type WithdrawalDelayerCallerRaw struct {
  69. Contract *WithdrawalDelayerCaller // Generic read-only contract binding to access the raw methods on
  70. }
  71. // WithdrawalDelayerTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract.
  72. type WithdrawalDelayerTransactorRaw struct {
  73. Contract *WithdrawalDelayerTransactor // Generic write-only contract binding to access the raw methods on
  74. }
  75. // NewWithdrawalDelayer creates a new instance of WithdrawalDelayer, bound to a specific deployed contract.
  76. func NewWithdrawalDelayer(address common.Address, backend bind.ContractBackend) (*WithdrawalDelayer, error) {
  77. contract, err := bindWithdrawalDelayer(address, backend, backend, backend)
  78. if err != nil {
  79. return nil, err
  80. }
  81. return &WithdrawalDelayer{WithdrawalDelayerCaller: WithdrawalDelayerCaller{contract: contract}, WithdrawalDelayerTransactor: WithdrawalDelayerTransactor{contract: contract}, WithdrawalDelayerFilterer: WithdrawalDelayerFilterer{contract: contract}}, nil
  82. }
  83. // NewWithdrawalDelayerCaller creates a new read-only instance of WithdrawalDelayer, bound to a specific deployed contract.
  84. func NewWithdrawalDelayerCaller(address common.Address, caller bind.ContractCaller) (*WithdrawalDelayerCaller, error) {
  85. contract, err := bindWithdrawalDelayer(address, caller, nil, nil)
  86. if err != nil {
  87. return nil, err
  88. }
  89. return &WithdrawalDelayerCaller{contract: contract}, nil
  90. }
  91. // NewWithdrawalDelayerTransactor creates a new write-only instance of WithdrawalDelayer, bound to a specific deployed contract.
  92. func NewWithdrawalDelayerTransactor(address common.Address, transactor bind.ContractTransactor) (*WithdrawalDelayerTransactor, error) {
  93. contract, err := bindWithdrawalDelayer(address, nil, transactor, nil)
  94. if err != nil {
  95. return nil, err
  96. }
  97. return &WithdrawalDelayerTransactor{contract: contract}, nil
  98. }
  99. // NewWithdrawalDelayerFilterer creates a new log filterer instance of WithdrawalDelayer, bound to a specific deployed contract.
  100. func NewWithdrawalDelayerFilterer(address common.Address, filterer bind.ContractFilterer) (*WithdrawalDelayerFilterer, error) {
  101. contract, err := bindWithdrawalDelayer(address, nil, nil, filterer)
  102. if err != nil {
  103. return nil, err
  104. }
  105. return &WithdrawalDelayerFilterer{contract: contract}, nil
  106. }
  107. // bindWithdrawalDelayer binds a generic wrapper to an already deployed contract.
  108. func bindWithdrawalDelayer(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) {
  109. parsed, err := abi.JSON(strings.NewReader(WithdrawalDelayerABI))
  110. if err != nil {
  111. return nil, err
  112. }
  113. return bind.NewBoundContract(address, parsed, caller, transactor, filterer), nil
  114. }
  115. // Call invokes the (constant) contract method with params as input values and
  116. // sets the output to result. The result type might be a single field for simple
  117. // returns, a slice of interfaces for anonymous returns and a struct for named
  118. // returns.
  119. func (_WithdrawalDelayer *WithdrawalDelayerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error {
  120. return _WithdrawalDelayer.Contract.WithdrawalDelayerCaller.contract.Call(opts, result, method, params...)
  121. }
  122. // Transfer initiates a plain transaction to move funds to the contract, calling
  123. // its default method if one is available.
  124. func (_WithdrawalDelayer *WithdrawalDelayerRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) {
  125. return _WithdrawalDelayer.Contract.WithdrawalDelayerTransactor.contract.Transfer(opts)
  126. }
  127. // Transact invokes the (paid) contract method with params as input values.
  128. func (_WithdrawalDelayer *WithdrawalDelayerRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) {
  129. return _WithdrawalDelayer.Contract.WithdrawalDelayerTransactor.contract.Transact(opts, method, params...)
  130. }
  131. // Call invokes the (constant) contract method with params as input values and
  132. // sets the output to result. The result type might be a single field for simple
  133. // returns, a slice of interfaces for anonymous returns and a struct for named
  134. // returns.
  135. func (_WithdrawalDelayer *WithdrawalDelayerCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error {
  136. return _WithdrawalDelayer.Contract.contract.Call(opts, result, method, params...)
  137. }
  138. // Transfer initiates a plain transaction to move funds to the contract, calling
  139. // its default method if one is available.
  140. func (_WithdrawalDelayer *WithdrawalDelayerTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) {
  141. return _WithdrawalDelayer.Contract.contract.Transfer(opts)
  142. }
  143. // Transact invokes the (paid) contract method with params as input values.
  144. func (_WithdrawalDelayer *WithdrawalDelayerTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) {
  145. return _WithdrawalDelayer.Contract.contract.Transact(opts, method, params...)
  146. }
  147. // MAXEMERGENCYMODETIME is a free data retrieval call binding the contract method 0xb4b8e39d.
  148. //
  149. // Solidity: function MAX_EMERGENCY_MODE_TIME() view returns(uint64)
  150. func (_WithdrawalDelayer *WithdrawalDelayerCaller) MAXEMERGENCYMODETIME(opts *bind.CallOpts) (uint64, error) {
  151. var out []interface{}
  152. err := _WithdrawalDelayer.contract.Call(opts, &out, "MAX_EMERGENCY_MODE_TIME")
  153. if err != nil {
  154. return *new(uint64), err
  155. }
  156. out0 := *abi.ConvertType(out[0], new(uint64)).(*uint64)
  157. return out0, err
  158. }
  159. // MAXEMERGENCYMODETIME is a free data retrieval call binding the contract method 0xb4b8e39d.
  160. //
  161. // Solidity: function MAX_EMERGENCY_MODE_TIME() view returns(uint64)
  162. func (_WithdrawalDelayer *WithdrawalDelayerSession) MAXEMERGENCYMODETIME() (uint64, error) {
  163. return _WithdrawalDelayer.Contract.MAXEMERGENCYMODETIME(&_WithdrawalDelayer.CallOpts)
  164. }
  165. // MAXEMERGENCYMODETIME is a free data retrieval call binding the contract method 0xb4b8e39d.
  166. //
  167. // Solidity: function MAX_EMERGENCY_MODE_TIME() view returns(uint64)
  168. func (_WithdrawalDelayer *WithdrawalDelayerCallerSession) MAXEMERGENCYMODETIME() (uint64, error) {
  169. return _WithdrawalDelayer.Contract.MAXEMERGENCYMODETIME(&_WithdrawalDelayer.CallOpts)
  170. }
  171. // MAXWITHDRAWALDELAY is a free data retrieval call binding the contract method 0xa238f9df.
  172. //
  173. // Solidity: function MAX_WITHDRAWAL_DELAY() view returns(uint64)
  174. func (_WithdrawalDelayer *WithdrawalDelayerCaller) MAXWITHDRAWALDELAY(opts *bind.CallOpts) (uint64, error) {
  175. var out []interface{}
  176. err := _WithdrawalDelayer.contract.Call(opts, &out, "MAX_WITHDRAWAL_DELAY")
  177. if err != nil {
  178. return *new(uint64), err
  179. }
  180. out0 := *abi.ConvertType(out[0], new(uint64)).(*uint64)
  181. return out0, err
  182. }
  183. // MAXWITHDRAWALDELAY is a free data retrieval call binding the contract method 0xa238f9df.
  184. //
  185. // Solidity: function MAX_WITHDRAWAL_DELAY() view returns(uint64)
  186. func (_WithdrawalDelayer *WithdrawalDelayerSession) MAXWITHDRAWALDELAY() (uint64, error) {
  187. return _WithdrawalDelayer.Contract.MAXWITHDRAWALDELAY(&_WithdrawalDelayer.CallOpts)
  188. }
  189. // MAXWITHDRAWALDELAY is a free data retrieval call binding the contract method 0xa238f9df.
  190. //
  191. // Solidity: function MAX_WITHDRAWAL_DELAY() view returns(uint64)
  192. func (_WithdrawalDelayer *WithdrawalDelayerCallerSession) MAXWITHDRAWALDELAY() (uint64, error) {
  193. return _WithdrawalDelayer.Contract.MAXWITHDRAWALDELAY(&_WithdrawalDelayer.CallOpts)
  194. }
  195. // DepositInfo is a free data retrieval call binding the contract method 0x493b0170.
  196. //
  197. // Solidity: function depositInfo(address _owner, address _token) view returns(uint192, uint64)
  198. func (_WithdrawalDelayer *WithdrawalDelayerCaller) DepositInfo(opts *bind.CallOpts, _owner common.Address, _token common.Address) (*big.Int, uint64, error) {
  199. var out []interface{}
  200. err := _WithdrawalDelayer.contract.Call(opts, &out, "depositInfo", _owner, _token)
  201. if err != nil {
  202. return *new(*big.Int), *new(uint64), err
  203. }
  204. out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int)
  205. out1 := *abi.ConvertType(out[1], new(uint64)).(*uint64)
  206. return out0, out1, err
  207. }
  208. // DepositInfo is a free data retrieval call binding the contract method 0x493b0170.
  209. //
  210. // Solidity: function depositInfo(address _owner, address _token) view returns(uint192, uint64)
  211. func (_WithdrawalDelayer *WithdrawalDelayerSession) DepositInfo(_owner common.Address, _token common.Address) (*big.Int, uint64, error) {
  212. return _WithdrawalDelayer.Contract.DepositInfo(&_WithdrawalDelayer.CallOpts, _owner, _token)
  213. }
  214. // DepositInfo is a free data retrieval call binding the contract method 0x493b0170.
  215. //
  216. // Solidity: function depositInfo(address _owner, address _token) view returns(uint192, uint64)
  217. func (_WithdrawalDelayer *WithdrawalDelayerCallerSession) DepositInfo(_owner common.Address, _token common.Address) (*big.Int, uint64, error) {
  218. return _WithdrawalDelayer.Contract.DepositInfo(&_WithdrawalDelayer.CallOpts, _owner, _token)
  219. }
  220. // Deposits is a free data retrieval call binding the contract method 0x3d4dff7b.
  221. //
  222. // Solidity: function deposits(bytes32 ) view returns(uint192 amount, uint64 depositTimestamp)
  223. func (_WithdrawalDelayer *WithdrawalDelayerCaller) Deposits(opts *bind.CallOpts, arg0 [32]byte) (struct {
  224. Amount *big.Int
  225. DepositTimestamp uint64
  226. }, error) {
  227. var out []interface{}
  228. err := _WithdrawalDelayer.contract.Call(opts, &out, "deposits", arg0)
  229. outstruct := new(struct {
  230. Amount *big.Int
  231. DepositTimestamp uint64
  232. })
  233. outstruct.Amount = out[0].(*big.Int)
  234. outstruct.DepositTimestamp = out[1].(uint64)
  235. return *outstruct, err
  236. }
  237. // Deposits is a free data retrieval call binding the contract method 0x3d4dff7b.
  238. //
  239. // Solidity: function deposits(bytes32 ) view returns(uint192 amount, uint64 depositTimestamp)
  240. func (_WithdrawalDelayer *WithdrawalDelayerSession) Deposits(arg0 [32]byte) (struct {
  241. Amount *big.Int
  242. DepositTimestamp uint64
  243. }, error) {
  244. return _WithdrawalDelayer.Contract.Deposits(&_WithdrawalDelayer.CallOpts, arg0)
  245. }
  246. // Deposits is a free data retrieval call binding the contract method 0x3d4dff7b.
  247. //
  248. // Solidity: function deposits(bytes32 ) view returns(uint192 amount, uint64 depositTimestamp)
  249. func (_WithdrawalDelayer *WithdrawalDelayerCallerSession) Deposits(arg0 [32]byte) (struct {
  250. Amount *big.Int
  251. DepositTimestamp uint64
  252. }, error) {
  253. return _WithdrawalDelayer.Contract.Deposits(&_WithdrawalDelayer.CallOpts, arg0)
  254. }
  255. // GetEmergencyCouncil is a free data retrieval call binding the contract method 0x99ef11c5.
  256. //
  257. // Solidity: function getEmergencyCouncil() view returns(address)
  258. func (_WithdrawalDelayer *WithdrawalDelayerCaller) GetEmergencyCouncil(opts *bind.CallOpts) (common.Address, error) {
  259. var out []interface{}
  260. err := _WithdrawalDelayer.contract.Call(opts, &out, "getEmergencyCouncil")
  261. if err != nil {
  262. return *new(common.Address), err
  263. }
  264. out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
  265. return out0, err
  266. }
  267. // GetEmergencyCouncil is a free data retrieval call binding the contract method 0x99ef11c5.
  268. //
  269. // Solidity: function getEmergencyCouncil() view returns(address)
  270. func (_WithdrawalDelayer *WithdrawalDelayerSession) GetEmergencyCouncil() (common.Address, error) {
  271. return _WithdrawalDelayer.Contract.GetEmergencyCouncil(&_WithdrawalDelayer.CallOpts)
  272. }
  273. // GetEmergencyCouncil is a free data retrieval call binding the contract method 0x99ef11c5.
  274. //
  275. // Solidity: function getEmergencyCouncil() view returns(address)
  276. func (_WithdrawalDelayer *WithdrawalDelayerCallerSession) GetEmergencyCouncil() (common.Address, error) {
  277. return _WithdrawalDelayer.Contract.GetEmergencyCouncil(&_WithdrawalDelayer.CallOpts)
  278. }
  279. // GetEmergencyModeStartingTime is a free data retrieval call binding the contract method 0x668cdd67.
  280. //
  281. // Solidity: function getEmergencyModeStartingTime() view returns(uint64)
  282. func (_WithdrawalDelayer *WithdrawalDelayerCaller) GetEmergencyModeStartingTime(opts *bind.CallOpts) (uint64, error) {
  283. var out []interface{}
  284. err := _WithdrawalDelayer.contract.Call(opts, &out, "getEmergencyModeStartingTime")
  285. if err != nil {
  286. return *new(uint64), err
  287. }
  288. out0 := *abi.ConvertType(out[0], new(uint64)).(*uint64)
  289. return out0, err
  290. }
  291. // GetEmergencyModeStartingTime is a free data retrieval call binding the contract method 0x668cdd67.
  292. //
  293. // Solidity: function getEmergencyModeStartingTime() view returns(uint64)
  294. func (_WithdrawalDelayer *WithdrawalDelayerSession) GetEmergencyModeStartingTime() (uint64, error) {
  295. return _WithdrawalDelayer.Contract.GetEmergencyModeStartingTime(&_WithdrawalDelayer.CallOpts)
  296. }
  297. // GetEmergencyModeStartingTime is a free data retrieval call binding the contract method 0x668cdd67.
  298. //
  299. // Solidity: function getEmergencyModeStartingTime() view returns(uint64)
  300. func (_WithdrawalDelayer *WithdrawalDelayerCallerSession) GetEmergencyModeStartingTime() (uint64, error) {
  301. return _WithdrawalDelayer.Contract.GetEmergencyModeStartingTime(&_WithdrawalDelayer.CallOpts)
  302. }
  303. // GetHermezGovernanceAddress is a free data retrieval call binding the contract method 0x0b21d430.
  304. //
  305. // Solidity: function getHermezGovernanceAddress() view returns(address)
  306. func (_WithdrawalDelayer *WithdrawalDelayerCaller) GetHermezGovernanceAddress(opts *bind.CallOpts) (common.Address, error) {
  307. var out []interface{}
  308. err := _WithdrawalDelayer.contract.Call(opts, &out, "getHermezGovernanceAddress")
  309. if err != nil {
  310. return *new(common.Address), err
  311. }
  312. out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
  313. return out0, err
  314. }
  315. // GetHermezGovernanceAddress is a free data retrieval call binding the contract method 0x0b21d430.
  316. //
  317. // Solidity: function getHermezGovernanceAddress() view returns(address)
  318. func (_WithdrawalDelayer *WithdrawalDelayerSession) GetHermezGovernanceAddress() (common.Address, error) {
  319. return _WithdrawalDelayer.Contract.GetHermezGovernanceAddress(&_WithdrawalDelayer.CallOpts)
  320. }
  321. // GetHermezGovernanceAddress is a free data retrieval call binding the contract method 0x0b21d430.
  322. //
  323. // Solidity: function getHermezGovernanceAddress() view returns(address)
  324. func (_WithdrawalDelayer *WithdrawalDelayerCallerSession) GetHermezGovernanceAddress() (common.Address, error) {
  325. return _WithdrawalDelayer.Contract.GetHermezGovernanceAddress(&_WithdrawalDelayer.CallOpts)
  326. }
  327. // GetWithdrawalDelay is a free data retrieval call binding the contract method 0x03160940.
  328. //
  329. // Solidity: function getWithdrawalDelay() view returns(uint64)
  330. func (_WithdrawalDelayer *WithdrawalDelayerCaller) GetWithdrawalDelay(opts *bind.CallOpts) (uint64, error) {
  331. var out []interface{}
  332. err := _WithdrawalDelayer.contract.Call(opts, &out, "getWithdrawalDelay")
  333. if err != nil {
  334. return *new(uint64), err
  335. }
  336. out0 := *abi.ConvertType(out[0], new(uint64)).(*uint64)
  337. return out0, err
  338. }
  339. // GetWithdrawalDelay is a free data retrieval call binding the contract method 0x03160940.
  340. //
  341. // Solidity: function getWithdrawalDelay() view returns(uint64)
  342. func (_WithdrawalDelayer *WithdrawalDelayerSession) GetWithdrawalDelay() (uint64, error) {
  343. return _WithdrawalDelayer.Contract.GetWithdrawalDelay(&_WithdrawalDelayer.CallOpts)
  344. }
  345. // GetWithdrawalDelay is a free data retrieval call binding the contract method 0x03160940.
  346. //
  347. // Solidity: function getWithdrawalDelay() view returns(uint64)
  348. func (_WithdrawalDelayer *WithdrawalDelayerCallerSession) GetWithdrawalDelay() (uint64, error) {
  349. return _WithdrawalDelayer.Contract.GetWithdrawalDelay(&_WithdrawalDelayer.CallOpts)
  350. }
  351. // HermezRollupAddress is a free data retrieval call binding the contract method 0x0fd266d7.
  352. //
  353. // Solidity: function hermezRollupAddress() view returns(address)
  354. func (_WithdrawalDelayer *WithdrawalDelayerCaller) HermezRollupAddress(opts *bind.CallOpts) (common.Address, error) {
  355. var out []interface{}
  356. err := _WithdrawalDelayer.contract.Call(opts, &out, "hermezRollupAddress")
  357. if err != nil {
  358. return *new(common.Address), err
  359. }
  360. out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
  361. return out0, err
  362. }
  363. // HermezRollupAddress is a free data retrieval call binding the contract method 0x0fd266d7.
  364. //
  365. // Solidity: function hermezRollupAddress() view returns(address)
  366. func (_WithdrawalDelayer *WithdrawalDelayerSession) HermezRollupAddress() (common.Address, error) {
  367. return _WithdrawalDelayer.Contract.HermezRollupAddress(&_WithdrawalDelayer.CallOpts)
  368. }
  369. // HermezRollupAddress is a free data retrieval call binding the contract method 0x0fd266d7.
  370. //
  371. // Solidity: function hermezRollupAddress() view returns(address)
  372. func (_WithdrawalDelayer *WithdrawalDelayerCallerSession) HermezRollupAddress() (common.Address, error) {
  373. return _WithdrawalDelayer.Contract.HermezRollupAddress(&_WithdrawalDelayer.CallOpts)
  374. }
  375. // IsEmergencyMode is a free data retrieval call binding the contract method 0x20a194b8.
  376. //
  377. // Solidity: function isEmergencyMode() view returns(bool)
  378. func (_WithdrawalDelayer *WithdrawalDelayerCaller) IsEmergencyMode(opts *bind.CallOpts) (bool, error) {
  379. var out []interface{}
  380. err := _WithdrawalDelayer.contract.Call(opts, &out, "isEmergencyMode")
  381. if err != nil {
  382. return *new(bool), err
  383. }
  384. out0 := *abi.ConvertType(out[0], new(bool)).(*bool)
  385. return out0, err
  386. }
  387. // IsEmergencyMode is a free data retrieval call binding the contract method 0x20a194b8.
  388. //
  389. // Solidity: function isEmergencyMode() view returns(bool)
  390. func (_WithdrawalDelayer *WithdrawalDelayerSession) IsEmergencyMode() (bool, error) {
  391. return _WithdrawalDelayer.Contract.IsEmergencyMode(&_WithdrawalDelayer.CallOpts)
  392. }
  393. // IsEmergencyMode is a free data retrieval call binding the contract method 0x20a194b8.
  394. //
  395. // Solidity: function isEmergencyMode() view returns(bool)
  396. func (_WithdrawalDelayer *WithdrawalDelayerCallerSession) IsEmergencyMode() (bool, error) {
  397. return _WithdrawalDelayer.Contract.IsEmergencyMode(&_WithdrawalDelayer.CallOpts)
  398. }
  399. // PendingEmergencyCouncil is a free data retrieval call binding the contract method 0x67fa2403.
  400. //
  401. // Solidity: function pendingEmergencyCouncil() view returns(address)
  402. func (_WithdrawalDelayer *WithdrawalDelayerCaller) PendingEmergencyCouncil(opts *bind.CallOpts) (common.Address, error) {
  403. var out []interface{}
  404. err := _WithdrawalDelayer.contract.Call(opts, &out, "pendingEmergencyCouncil")
  405. if err != nil {
  406. return *new(common.Address), err
  407. }
  408. out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
  409. return out0, err
  410. }
  411. // PendingEmergencyCouncil is a free data retrieval call binding the contract method 0x67fa2403.
  412. //
  413. // Solidity: function pendingEmergencyCouncil() view returns(address)
  414. func (_WithdrawalDelayer *WithdrawalDelayerSession) PendingEmergencyCouncil() (common.Address, error) {
  415. return _WithdrawalDelayer.Contract.PendingEmergencyCouncil(&_WithdrawalDelayer.CallOpts)
  416. }
  417. // PendingEmergencyCouncil is a free data retrieval call binding the contract method 0x67fa2403.
  418. //
  419. // Solidity: function pendingEmergencyCouncil() view returns(address)
  420. func (_WithdrawalDelayer *WithdrawalDelayerCallerSession) PendingEmergencyCouncil() (common.Address, error) {
  421. return _WithdrawalDelayer.Contract.PendingEmergencyCouncil(&_WithdrawalDelayer.CallOpts)
  422. }
  423. // PendingGovernance is a free data retrieval call binding the contract method 0xf39c38a0.
  424. //
  425. // Solidity: function pendingGovernance() view returns(address)
  426. func (_WithdrawalDelayer *WithdrawalDelayerCaller) PendingGovernance(opts *bind.CallOpts) (common.Address, error) {
  427. var out []interface{}
  428. err := _WithdrawalDelayer.contract.Call(opts, &out, "pendingGovernance")
  429. if err != nil {
  430. return *new(common.Address), err
  431. }
  432. out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
  433. return out0, err
  434. }
  435. // PendingGovernance is a free data retrieval call binding the contract method 0xf39c38a0.
  436. //
  437. // Solidity: function pendingGovernance() view returns(address)
  438. func (_WithdrawalDelayer *WithdrawalDelayerSession) PendingGovernance() (common.Address, error) {
  439. return _WithdrawalDelayer.Contract.PendingGovernance(&_WithdrawalDelayer.CallOpts)
  440. }
  441. // PendingGovernance is a free data retrieval call binding the contract method 0xf39c38a0.
  442. //
  443. // Solidity: function pendingGovernance() view returns(address)
  444. func (_WithdrawalDelayer *WithdrawalDelayerCallerSession) PendingGovernance() (common.Address, error) {
  445. return _WithdrawalDelayer.Contract.PendingGovernance(&_WithdrawalDelayer.CallOpts)
  446. }
  447. // ChangeWithdrawalDelay is a paid mutator transaction binding the contract method 0x0e670af5.
  448. //
  449. // Solidity: function changeWithdrawalDelay(uint64 _newWithdrawalDelay) returns()
  450. func (_WithdrawalDelayer *WithdrawalDelayerTransactor) ChangeWithdrawalDelay(opts *bind.TransactOpts, _newWithdrawalDelay uint64) (*types.Transaction, error) {
  451. return _WithdrawalDelayer.contract.Transact(opts, "changeWithdrawalDelay", _newWithdrawalDelay)
  452. }
  453. // ChangeWithdrawalDelay is a paid mutator transaction binding the contract method 0x0e670af5.
  454. //
  455. // Solidity: function changeWithdrawalDelay(uint64 _newWithdrawalDelay) returns()
  456. func (_WithdrawalDelayer *WithdrawalDelayerSession) ChangeWithdrawalDelay(_newWithdrawalDelay uint64) (*types.Transaction, error) {
  457. return _WithdrawalDelayer.Contract.ChangeWithdrawalDelay(&_WithdrawalDelayer.TransactOpts, _newWithdrawalDelay)
  458. }
  459. // ChangeWithdrawalDelay is a paid mutator transaction binding the contract method 0x0e670af5.
  460. //
  461. // Solidity: function changeWithdrawalDelay(uint64 _newWithdrawalDelay) returns()
  462. func (_WithdrawalDelayer *WithdrawalDelayerTransactorSession) ChangeWithdrawalDelay(_newWithdrawalDelay uint64) (*types.Transaction, error) {
  463. return _WithdrawalDelayer.Contract.ChangeWithdrawalDelay(&_WithdrawalDelayer.TransactOpts, _newWithdrawalDelay)
  464. }
  465. // ClaimEmergencyCouncil is a paid mutator transaction binding the contract method 0xca79033f.
  466. //
  467. // Solidity: function claimEmergencyCouncil() returns()
  468. func (_WithdrawalDelayer *WithdrawalDelayerTransactor) ClaimEmergencyCouncil(opts *bind.TransactOpts) (*types.Transaction, error) {
  469. return _WithdrawalDelayer.contract.Transact(opts, "claimEmergencyCouncil")
  470. }
  471. // ClaimEmergencyCouncil is a paid mutator transaction binding the contract method 0xca79033f.
  472. //
  473. // Solidity: function claimEmergencyCouncil() returns()
  474. func (_WithdrawalDelayer *WithdrawalDelayerSession) ClaimEmergencyCouncil() (*types.Transaction, error) {
  475. return _WithdrawalDelayer.Contract.ClaimEmergencyCouncil(&_WithdrawalDelayer.TransactOpts)
  476. }
  477. // ClaimEmergencyCouncil is a paid mutator transaction binding the contract method 0xca79033f.
  478. //
  479. // Solidity: function claimEmergencyCouncil() returns()
  480. func (_WithdrawalDelayer *WithdrawalDelayerTransactorSession) ClaimEmergencyCouncil() (*types.Transaction, error) {
  481. return _WithdrawalDelayer.Contract.ClaimEmergencyCouncil(&_WithdrawalDelayer.TransactOpts)
  482. }
  483. // ClaimGovernance is a paid mutator transaction binding the contract method 0x5d36b190.
  484. //
  485. // Solidity: function claimGovernance() returns()
  486. func (_WithdrawalDelayer *WithdrawalDelayerTransactor) ClaimGovernance(opts *bind.TransactOpts) (*types.Transaction, error) {
  487. return _WithdrawalDelayer.contract.Transact(opts, "claimGovernance")
  488. }
  489. // ClaimGovernance is a paid mutator transaction binding the contract method 0x5d36b190.
  490. //
  491. // Solidity: function claimGovernance() returns()
  492. func (_WithdrawalDelayer *WithdrawalDelayerSession) ClaimGovernance() (*types.Transaction, error) {
  493. return _WithdrawalDelayer.Contract.ClaimGovernance(&_WithdrawalDelayer.TransactOpts)
  494. }
  495. // ClaimGovernance is a paid mutator transaction binding the contract method 0x5d36b190.
  496. //
  497. // Solidity: function claimGovernance() returns()
  498. func (_WithdrawalDelayer *WithdrawalDelayerTransactorSession) ClaimGovernance() (*types.Transaction, error) {
  499. return _WithdrawalDelayer.Contract.ClaimGovernance(&_WithdrawalDelayer.TransactOpts)
  500. }
  501. // Deposit is a paid mutator transaction binding the contract method 0xcfc0b641.
  502. //
  503. // Solidity: function deposit(address _owner, address _token, uint192 _amount) payable returns()
  504. func (_WithdrawalDelayer *WithdrawalDelayerTransactor) Deposit(opts *bind.TransactOpts, _owner common.Address, _token common.Address, _amount *big.Int) (*types.Transaction, error) {
  505. return _WithdrawalDelayer.contract.Transact(opts, "deposit", _owner, _token, _amount)
  506. }
  507. // Deposit is a paid mutator transaction binding the contract method 0xcfc0b641.
  508. //
  509. // Solidity: function deposit(address _owner, address _token, uint192 _amount) payable returns()
  510. func (_WithdrawalDelayer *WithdrawalDelayerSession) Deposit(_owner common.Address, _token common.Address, _amount *big.Int) (*types.Transaction, error) {
  511. return _WithdrawalDelayer.Contract.Deposit(&_WithdrawalDelayer.TransactOpts, _owner, _token, _amount)
  512. }
  513. // Deposit is a paid mutator transaction binding the contract method 0xcfc0b641.
  514. //
  515. // Solidity: function deposit(address _owner, address _token, uint192 _amount) payable returns()
  516. func (_WithdrawalDelayer *WithdrawalDelayerTransactorSession) Deposit(_owner common.Address, _token common.Address, _amount *big.Int) (*types.Transaction, error) {
  517. return _WithdrawalDelayer.Contract.Deposit(&_WithdrawalDelayer.TransactOpts, _owner, _token, _amount)
  518. }
  519. // EnableEmergencyMode is a paid mutator transaction binding the contract method 0xc5b1c7d0.
  520. //
  521. // Solidity: function enableEmergencyMode() returns()
  522. func (_WithdrawalDelayer *WithdrawalDelayerTransactor) EnableEmergencyMode(opts *bind.TransactOpts) (*types.Transaction, error) {
  523. return _WithdrawalDelayer.contract.Transact(opts, "enableEmergencyMode")
  524. }
  525. // EnableEmergencyMode is a paid mutator transaction binding the contract method 0xc5b1c7d0.
  526. //
  527. // Solidity: function enableEmergencyMode() returns()
  528. func (_WithdrawalDelayer *WithdrawalDelayerSession) EnableEmergencyMode() (*types.Transaction, error) {
  529. return _WithdrawalDelayer.Contract.EnableEmergencyMode(&_WithdrawalDelayer.TransactOpts)
  530. }
  531. // EnableEmergencyMode is a paid mutator transaction binding the contract method 0xc5b1c7d0.
  532. //
  533. // Solidity: function enableEmergencyMode() returns()
  534. func (_WithdrawalDelayer *WithdrawalDelayerTransactorSession) EnableEmergencyMode() (*types.Transaction, error) {
  535. return _WithdrawalDelayer.Contract.EnableEmergencyMode(&_WithdrawalDelayer.TransactOpts)
  536. }
  537. // EscapeHatchWithdrawal is a paid mutator transaction binding the contract method 0x7fd6b102.
  538. //
  539. // Solidity: function escapeHatchWithdrawal(address _to, address _token, uint256 _amount) returns()
  540. func (_WithdrawalDelayer *WithdrawalDelayerTransactor) EscapeHatchWithdrawal(opts *bind.TransactOpts, _to common.Address, _token common.Address, _amount *big.Int) (*types.Transaction, error) {
  541. return _WithdrawalDelayer.contract.Transact(opts, "escapeHatchWithdrawal", _to, _token, _amount)
  542. }
  543. // EscapeHatchWithdrawal is a paid mutator transaction binding the contract method 0x7fd6b102.
  544. //
  545. // Solidity: function escapeHatchWithdrawal(address _to, address _token, uint256 _amount) returns()
  546. func (_WithdrawalDelayer *WithdrawalDelayerSession) EscapeHatchWithdrawal(_to common.Address, _token common.Address, _amount *big.Int) (*types.Transaction, error) {
  547. return _WithdrawalDelayer.Contract.EscapeHatchWithdrawal(&_WithdrawalDelayer.TransactOpts, _to, _token, _amount)
  548. }
  549. // EscapeHatchWithdrawal is a paid mutator transaction binding the contract method 0x7fd6b102.
  550. //
  551. // Solidity: function escapeHatchWithdrawal(address _to, address _token, uint256 _amount) returns()
  552. func (_WithdrawalDelayer *WithdrawalDelayerTransactorSession) EscapeHatchWithdrawal(_to common.Address, _token common.Address, _amount *big.Int) (*types.Transaction, error) {
  553. return _WithdrawalDelayer.Contract.EscapeHatchWithdrawal(&_WithdrawalDelayer.TransactOpts, _to, _token, _amount)
  554. }
  555. // TransferEmergencyCouncil is a paid mutator transaction binding the contract method 0xdb2a1a81.
  556. //
  557. // Solidity: function transferEmergencyCouncil(address newEmergencyCouncil) returns()
  558. func (_WithdrawalDelayer *WithdrawalDelayerTransactor) TransferEmergencyCouncil(opts *bind.TransactOpts, newEmergencyCouncil common.Address) (*types.Transaction, error) {
  559. return _WithdrawalDelayer.contract.Transact(opts, "transferEmergencyCouncil", newEmergencyCouncil)
  560. }
  561. // TransferEmergencyCouncil is a paid mutator transaction binding the contract method 0xdb2a1a81.
  562. //
  563. // Solidity: function transferEmergencyCouncil(address newEmergencyCouncil) returns()
  564. func (_WithdrawalDelayer *WithdrawalDelayerSession) TransferEmergencyCouncil(newEmergencyCouncil common.Address) (*types.Transaction, error) {
  565. return _WithdrawalDelayer.Contract.TransferEmergencyCouncil(&_WithdrawalDelayer.TransactOpts, newEmergencyCouncil)
  566. }
  567. // TransferEmergencyCouncil is a paid mutator transaction binding the contract method 0xdb2a1a81.
  568. //
  569. // Solidity: function transferEmergencyCouncil(address newEmergencyCouncil) returns()
  570. func (_WithdrawalDelayer *WithdrawalDelayerTransactorSession) TransferEmergencyCouncil(newEmergencyCouncil common.Address) (*types.Transaction, error) {
  571. return _WithdrawalDelayer.Contract.TransferEmergencyCouncil(&_WithdrawalDelayer.TransactOpts, newEmergencyCouncil)
  572. }
  573. // TransferGovernance is a paid mutator transaction binding the contract method 0xd38bfff4.
  574. //
  575. // Solidity: function transferGovernance(address newGovernance) returns()
  576. func (_WithdrawalDelayer *WithdrawalDelayerTransactor) TransferGovernance(opts *bind.TransactOpts, newGovernance common.Address) (*types.Transaction, error) {
  577. return _WithdrawalDelayer.contract.Transact(opts, "transferGovernance", newGovernance)
  578. }
  579. // TransferGovernance is a paid mutator transaction binding the contract method 0xd38bfff4.
  580. //
  581. // Solidity: function transferGovernance(address newGovernance) returns()
  582. func (_WithdrawalDelayer *WithdrawalDelayerSession) TransferGovernance(newGovernance common.Address) (*types.Transaction, error) {
  583. return _WithdrawalDelayer.Contract.TransferGovernance(&_WithdrawalDelayer.TransactOpts, newGovernance)
  584. }
  585. // TransferGovernance is a paid mutator transaction binding the contract method 0xd38bfff4.
  586. //
  587. // Solidity: function transferGovernance(address newGovernance) returns()
  588. func (_WithdrawalDelayer *WithdrawalDelayerTransactorSession) TransferGovernance(newGovernance common.Address) (*types.Transaction, error) {
  589. return _WithdrawalDelayer.Contract.TransferGovernance(&_WithdrawalDelayer.TransactOpts, newGovernance)
  590. }
  591. // Withdrawal is a paid mutator transaction binding the contract method 0xde35f282.
  592. //
  593. // Solidity: function withdrawal(address _owner, address _token) returns()
  594. func (_WithdrawalDelayer *WithdrawalDelayerTransactor) Withdrawal(opts *bind.TransactOpts, _owner common.Address, _token common.Address) (*types.Transaction, error) {
  595. return _WithdrawalDelayer.contract.Transact(opts, "withdrawal", _owner, _token)
  596. }
  597. // Withdrawal is a paid mutator transaction binding the contract method 0xde35f282.
  598. //
  599. // Solidity: function withdrawal(address _owner, address _token) returns()
  600. func (_WithdrawalDelayer *WithdrawalDelayerSession) Withdrawal(_owner common.Address, _token common.Address) (*types.Transaction, error) {
  601. return _WithdrawalDelayer.Contract.Withdrawal(&_WithdrawalDelayer.TransactOpts, _owner, _token)
  602. }
  603. // Withdrawal is a paid mutator transaction binding the contract method 0xde35f282.
  604. //
  605. // Solidity: function withdrawal(address _owner, address _token) returns()
  606. func (_WithdrawalDelayer *WithdrawalDelayerTransactorSession) Withdrawal(_owner common.Address, _token common.Address) (*types.Transaction, error) {
  607. return _WithdrawalDelayer.Contract.Withdrawal(&_WithdrawalDelayer.TransactOpts, _owner, _token)
  608. }
  609. // WithdrawalDelayerInitializer is a paid mutator transaction binding the contract method 0x42cb7216.
  610. //
  611. // Solidity: function withdrawalDelayerInitializer(uint64 _initialWithdrawalDelay, address _initialHermezRollup, address _initialHermezGovernanceAddress, address _initialEmergencyCouncil) returns()
  612. func (_WithdrawalDelayer *WithdrawalDelayerTransactor) WithdrawalDelayerInitializer(opts *bind.TransactOpts, _initialWithdrawalDelay uint64, _initialHermezRollup common.Address, _initialHermezGovernanceAddress common.Address, _initialEmergencyCouncil common.Address) (*types.Transaction, error) {
  613. return _WithdrawalDelayer.contract.Transact(opts, "withdrawalDelayerInitializer", _initialWithdrawalDelay, _initialHermezRollup, _initialHermezGovernanceAddress, _initialEmergencyCouncil)
  614. }
  615. // WithdrawalDelayerInitializer is a paid mutator transaction binding the contract method 0x42cb7216.
  616. //
  617. // Solidity: function withdrawalDelayerInitializer(uint64 _initialWithdrawalDelay, address _initialHermezRollup, address _initialHermezGovernanceAddress, address _initialEmergencyCouncil) returns()
  618. func (_WithdrawalDelayer *WithdrawalDelayerSession) WithdrawalDelayerInitializer(_initialWithdrawalDelay uint64, _initialHermezRollup common.Address, _initialHermezGovernanceAddress common.Address, _initialEmergencyCouncil common.Address) (*types.Transaction, error) {
  619. return _WithdrawalDelayer.Contract.WithdrawalDelayerInitializer(&_WithdrawalDelayer.TransactOpts, _initialWithdrawalDelay, _initialHermezRollup, _initialHermezGovernanceAddress, _initialEmergencyCouncil)
  620. }
  621. // WithdrawalDelayerInitializer is a paid mutator transaction binding the contract method 0x42cb7216.
  622. //
  623. // Solidity: function withdrawalDelayerInitializer(uint64 _initialWithdrawalDelay, address _initialHermezRollup, address _initialHermezGovernanceAddress, address _initialEmergencyCouncil) returns()
  624. func (_WithdrawalDelayer *WithdrawalDelayerTransactorSession) WithdrawalDelayerInitializer(_initialWithdrawalDelay uint64, _initialHermezRollup common.Address, _initialHermezGovernanceAddress common.Address, _initialEmergencyCouncil common.Address) (*types.Transaction, error) {
  625. return _WithdrawalDelayer.Contract.WithdrawalDelayerInitializer(&_WithdrawalDelayer.TransactOpts, _initialWithdrawalDelay, _initialHermezRollup, _initialHermezGovernanceAddress, _initialEmergencyCouncil)
  626. }
  627. // WithdrawalDelayerDepositIterator is returned from FilterDeposit and is used to iterate over the raw logs and unpacked data for Deposit events raised by the WithdrawalDelayer contract.
  628. type WithdrawalDelayerDepositIterator struct {
  629. Event *WithdrawalDelayerDeposit // Event containing the contract specifics and raw log
  630. contract *bind.BoundContract // Generic contract to use for unpacking event data
  631. event string // Event name to use for unpacking event data
  632. logs chan types.Log // Log channel receiving the found contract events
  633. sub ethereum.Subscription // Subscription for errors, completion and termination
  634. done bool // Whether the subscription completed delivering logs
  635. fail error // Occurred error to stop iteration
  636. }
  637. // Next advances the iterator to the subsequent event, returning whether there
  638. // are any more events found. In case of a retrieval or parsing error, false is
  639. // returned and Error() can be queried for the exact failure.
  640. func (it *WithdrawalDelayerDepositIterator) Next() bool {
  641. // If the iterator failed, stop iterating
  642. if it.fail != nil {
  643. return false
  644. }
  645. // If the iterator completed, deliver directly whatever's available
  646. if it.done {
  647. select {
  648. case log := <-it.logs:
  649. it.Event = new(WithdrawalDelayerDeposit)
  650. if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
  651. it.fail = err
  652. return false
  653. }
  654. it.Event.Raw = log
  655. return true
  656. default:
  657. return false
  658. }
  659. }
  660. // Iterator still in progress, wait for either a data or an error event
  661. select {
  662. case log := <-it.logs:
  663. it.Event = new(WithdrawalDelayerDeposit)
  664. if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
  665. it.fail = err
  666. return false
  667. }
  668. it.Event.Raw = log
  669. return true
  670. case err := <-it.sub.Err():
  671. it.done = true
  672. it.fail = err
  673. return it.Next()
  674. }
  675. }
  676. // Error returns any retrieval or parsing error occurred during filtering.
  677. func (it *WithdrawalDelayerDepositIterator) Error() error {
  678. return it.fail
  679. }
  680. // Close terminates the iteration process, releasing any pending underlying
  681. // resources.
  682. func (it *WithdrawalDelayerDepositIterator) Close() error {
  683. it.sub.Unsubscribe()
  684. return nil
  685. }
  686. // WithdrawalDelayerDeposit represents a Deposit event raised by the WithdrawalDelayer contract.
  687. type WithdrawalDelayerDeposit struct {
  688. Owner common.Address
  689. Token common.Address
  690. Amount *big.Int
  691. DepositTimestamp uint64
  692. Raw types.Log // Blockchain specific contextual infos
  693. }
  694. // FilterDeposit is a free log retrieval operation binding the contract event 0x41219b99485f78192a5b9b1be28c7d53c3a2bdbe7900ae40c79fae8d9d6108fd.
  695. //
  696. // Solidity: event Deposit(address indexed owner, address indexed token, uint192 amount, uint64 depositTimestamp)
  697. func (_WithdrawalDelayer *WithdrawalDelayerFilterer) FilterDeposit(opts *bind.FilterOpts, owner []common.Address, token []common.Address) (*WithdrawalDelayerDepositIterator, error) {
  698. var ownerRule []interface{}
  699. for _, ownerItem := range owner {
  700. ownerRule = append(ownerRule, ownerItem)
  701. }
  702. var tokenRule []interface{}
  703. for _, tokenItem := range token {
  704. tokenRule = append(tokenRule, tokenItem)
  705. }
  706. logs, sub, err := _WithdrawalDelayer.contract.FilterLogs(opts, "Deposit", ownerRule, tokenRule)
  707. if err != nil {
  708. return nil, err
  709. }
  710. return &WithdrawalDelayerDepositIterator{contract: _WithdrawalDelayer.contract, event: "Deposit", logs: logs, sub: sub}, nil
  711. }
  712. // WatchDeposit is a free log subscription operation binding the contract event 0x41219b99485f78192a5b9b1be28c7d53c3a2bdbe7900ae40c79fae8d9d6108fd.
  713. //
  714. // Solidity: event Deposit(address indexed owner, address indexed token, uint192 amount, uint64 depositTimestamp)
  715. func (_WithdrawalDelayer *WithdrawalDelayerFilterer) WatchDeposit(opts *bind.WatchOpts, sink chan<- *WithdrawalDelayerDeposit, owner []common.Address, token []common.Address) (event.Subscription, error) {
  716. var ownerRule []interface{}
  717. for _, ownerItem := range owner {
  718. ownerRule = append(ownerRule, ownerItem)
  719. }
  720. var tokenRule []interface{}
  721. for _, tokenItem := range token {
  722. tokenRule = append(tokenRule, tokenItem)
  723. }
  724. logs, sub, err := _WithdrawalDelayer.contract.WatchLogs(opts, "Deposit", ownerRule, tokenRule)
  725. if err != nil {
  726. return nil, err
  727. }
  728. return event.NewSubscription(func(quit <-chan struct{}) error {
  729. defer sub.Unsubscribe()
  730. for {
  731. select {
  732. case log := <-logs:
  733. // New log arrived, parse the event and forward to the user
  734. event := new(WithdrawalDelayerDeposit)
  735. if err := _WithdrawalDelayer.contract.UnpackLog(event, "Deposit", log); err != nil {
  736. return err
  737. }
  738. event.Raw = log
  739. select {
  740. case sink <- event:
  741. case err := <-sub.Err():
  742. return err
  743. case <-quit:
  744. return nil
  745. }
  746. case err := <-sub.Err():
  747. return err
  748. case <-quit:
  749. return nil
  750. }
  751. }
  752. }), nil
  753. }
  754. // ParseDeposit is a log parse operation binding the contract event 0x41219b99485f78192a5b9b1be28c7d53c3a2bdbe7900ae40c79fae8d9d6108fd.
  755. //
  756. // Solidity: event Deposit(address indexed owner, address indexed token, uint192 amount, uint64 depositTimestamp)
  757. func (_WithdrawalDelayer *WithdrawalDelayerFilterer) ParseDeposit(log types.Log) (*WithdrawalDelayerDeposit, error) {
  758. event := new(WithdrawalDelayerDeposit)
  759. if err := _WithdrawalDelayer.contract.UnpackLog(event, "Deposit", log); err != nil {
  760. return nil, err
  761. }
  762. event.Raw = log
  763. return event, nil
  764. }
  765. // WithdrawalDelayerEmergencyModeEnabledIterator is returned from FilterEmergencyModeEnabled and is used to iterate over the raw logs and unpacked data for EmergencyModeEnabled events raised by the WithdrawalDelayer contract.
  766. type WithdrawalDelayerEmergencyModeEnabledIterator struct {
  767. Event *WithdrawalDelayerEmergencyModeEnabled // Event containing the contract specifics and raw log
  768. contract *bind.BoundContract // Generic contract to use for unpacking event data
  769. event string // Event name to use for unpacking event data
  770. logs chan types.Log // Log channel receiving the found contract events
  771. sub ethereum.Subscription // Subscription for errors, completion and termination
  772. done bool // Whether the subscription completed delivering logs
  773. fail error // Occurred error to stop iteration
  774. }
  775. // Next advances the iterator to the subsequent event, returning whether there
  776. // are any more events found. In case of a retrieval or parsing error, false is
  777. // returned and Error() can be queried for the exact failure.
  778. func (it *WithdrawalDelayerEmergencyModeEnabledIterator) Next() bool {
  779. // If the iterator failed, stop iterating
  780. if it.fail != nil {
  781. return false
  782. }
  783. // If the iterator completed, deliver directly whatever's available
  784. if it.done {
  785. select {
  786. case log := <-it.logs:
  787. it.Event = new(WithdrawalDelayerEmergencyModeEnabled)
  788. if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
  789. it.fail = err
  790. return false
  791. }
  792. it.Event.Raw = log
  793. return true
  794. default:
  795. return false
  796. }
  797. }
  798. // Iterator still in progress, wait for either a data or an error event
  799. select {
  800. case log := <-it.logs:
  801. it.Event = new(WithdrawalDelayerEmergencyModeEnabled)
  802. if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
  803. it.fail = err
  804. return false
  805. }
  806. it.Event.Raw = log
  807. return true
  808. case err := <-it.sub.Err():
  809. it.done = true
  810. it.fail = err
  811. return it.Next()
  812. }
  813. }
  814. // Error returns any retrieval or parsing error occurred during filtering.
  815. func (it *WithdrawalDelayerEmergencyModeEnabledIterator) Error() error {
  816. return it.fail
  817. }
  818. // Close terminates the iteration process, releasing any pending underlying
  819. // resources.
  820. func (it *WithdrawalDelayerEmergencyModeEnabledIterator) Close() error {
  821. it.sub.Unsubscribe()
  822. return nil
  823. }
  824. // WithdrawalDelayerEmergencyModeEnabled represents a EmergencyModeEnabled event raised by the WithdrawalDelayer contract.
  825. type WithdrawalDelayerEmergencyModeEnabled struct {
  826. Raw types.Log // Blockchain specific contextual infos
  827. }
  828. // FilterEmergencyModeEnabled is a free log retrieval operation binding the contract event 0x2064d51aa5a8bd67928c7675e267e05c67ad5adf7c9098d0a602d01f36fda9c5.
  829. //
  830. // Solidity: event EmergencyModeEnabled()
  831. func (_WithdrawalDelayer *WithdrawalDelayerFilterer) FilterEmergencyModeEnabled(opts *bind.FilterOpts) (*WithdrawalDelayerEmergencyModeEnabledIterator, error) {
  832. logs, sub, err := _WithdrawalDelayer.contract.FilterLogs(opts, "EmergencyModeEnabled")
  833. if err != nil {
  834. return nil, err
  835. }
  836. return &WithdrawalDelayerEmergencyModeEnabledIterator{contract: _WithdrawalDelayer.contract, event: "EmergencyModeEnabled", logs: logs, sub: sub}, nil
  837. }
  838. // WatchEmergencyModeEnabled is a free log subscription operation binding the contract event 0x2064d51aa5a8bd67928c7675e267e05c67ad5adf7c9098d0a602d01f36fda9c5.
  839. //
  840. // Solidity: event EmergencyModeEnabled()
  841. func (_WithdrawalDelayer *WithdrawalDelayerFilterer) WatchEmergencyModeEnabled(opts *bind.WatchOpts, sink chan<- *WithdrawalDelayerEmergencyModeEnabled) (event.Subscription, error) {
  842. logs, sub, err := _WithdrawalDelayer.contract.WatchLogs(opts, "EmergencyModeEnabled")
  843. if err != nil {
  844. return nil, err
  845. }
  846. return event.NewSubscription(func(quit <-chan struct{}) error {
  847. defer sub.Unsubscribe()
  848. for {
  849. select {
  850. case log := <-logs:
  851. // New log arrived, parse the event and forward to the user
  852. event := new(WithdrawalDelayerEmergencyModeEnabled)
  853. if err := _WithdrawalDelayer.contract.UnpackLog(event, "EmergencyModeEnabled", log); err != nil {
  854. return err
  855. }
  856. event.Raw = log
  857. select {
  858. case sink <- event:
  859. case err := <-sub.Err():
  860. return err
  861. case <-quit:
  862. return nil
  863. }
  864. case err := <-sub.Err():
  865. return err
  866. case <-quit:
  867. return nil
  868. }
  869. }
  870. }), nil
  871. }
  872. // ParseEmergencyModeEnabled is a log parse operation binding the contract event 0x2064d51aa5a8bd67928c7675e267e05c67ad5adf7c9098d0a602d01f36fda9c5.
  873. //
  874. // Solidity: event EmergencyModeEnabled()
  875. func (_WithdrawalDelayer *WithdrawalDelayerFilterer) ParseEmergencyModeEnabled(log types.Log) (*WithdrawalDelayerEmergencyModeEnabled, error) {
  876. event := new(WithdrawalDelayerEmergencyModeEnabled)
  877. if err := _WithdrawalDelayer.contract.UnpackLog(event, "EmergencyModeEnabled", log); err != nil {
  878. return nil, err
  879. }
  880. event.Raw = log
  881. return event, nil
  882. }
  883. // WithdrawalDelayerEscapeHatchWithdrawalIterator is returned from FilterEscapeHatchWithdrawal and is used to iterate over the raw logs and unpacked data for EscapeHatchWithdrawal events raised by the WithdrawalDelayer contract.
  884. type WithdrawalDelayerEscapeHatchWithdrawalIterator struct {
  885. Event *WithdrawalDelayerEscapeHatchWithdrawal // Event containing the contract specifics and raw log
  886. contract *bind.BoundContract // Generic contract to use for unpacking event data
  887. event string // Event name to use for unpacking event data
  888. logs chan types.Log // Log channel receiving the found contract events
  889. sub ethereum.Subscription // Subscription for errors, completion and termination
  890. done bool // Whether the subscription completed delivering logs
  891. fail error // Occurred error to stop iteration
  892. }
  893. // Next advances the iterator to the subsequent event, returning whether there
  894. // are any more events found. In case of a retrieval or parsing error, false is
  895. // returned and Error() can be queried for the exact failure.
  896. func (it *WithdrawalDelayerEscapeHatchWithdrawalIterator) Next() bool {
  897. // If the iterator failed, stop iterating
  898. if it.fail != nil {
  899. return false
  900. }
  901. // If the iterator completed, deliver directly whatever's available
  902. if it.done {
  903. select {
  904. case log := <-it.logs:
  905. it.Event = new(WithdrawalDelayerEscapeHatchWithdrawal)
  906. if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
  907. it.fail = err
  908. return false
  909. }
  910. it.Event.Raw = log
  911. return true
  912. default:
  913. return false
  914. }
  915. }
  916. // Iterator still in progress, wait for either a data or an error event
  917. select {
  918. case log := <-it.logs:
  919. it.Event = new(WithdrawalDelayerEscapeHatchWithdrawal)
  920. if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
  921. it.fail = err
  922. return false
  923. }
  924. it.Event.Raw = log
  925. return true
  926. case err := <-it.sub.Err():
  927. it.done = true
  928. it.fail = err
  929. return it.Next()
  930. }
  931. }
  932. // Error returns any retrieval or parsing error occurred during filtering.
  933. func (it *WithdrawalDelayerEscapeHatchWithdrawalIterator) Error() error {
  934. return it.fail
  935. }
  936. // Close terminates the iteration process, releasing any pending underlying
  937. // resources.
  938. func (it *WithdrawalDelayerEscapeHatchWithdrawalIterator) Close() error {
  939. it.sub.Unsubscribe()
  940. return nil
  941. }
  942. // WithdrawalDelayerEscapeHatchWithdrawal represents a EscapeHatchWithdrawal event raised by the WithdrawalDelayer contract.
  943. type WithdrawalDelayerEscapeHatchWithdrawal struct {
  944. Who common.Address
  945. To common.Address
  946. Token common.Address
  947. Amount *big.Int
  948. Raw types.Log // Blockchain specific contextual infos
  949. }
  950. // FilterEscapeHatchWithdrawal is a free log retrieval operation binding the contract event 0xde200220117ba95c9a6c4a1a13bb06b0b7be90faa85c8fb4576630119f891693.
  951. //
  952. // Solidity: event EscapeHatchWithdrawal(address indexed who, address indexed to, address indexed token, uint256 amount)
  953. func (_WithdrawalDelayer *WithdrawalDelayerFilterer) FilterEscapeHatchWithdrawal(opts *bind.FilterOpts, who []common.Address, to []common.Address, token []common.Address) (*WithdrawalDelayerEscapeHatchWithdrawalIterator, error) {
  954. var whoRule []interface{}
  955. for _, whoItem := range who {
  956. whoRule = append(whoRule, whoItem)
  957. }
  958. var toRule []interface{}
  959. for _, toItem := range to {
  960. toRule = append(toRule, toItem)
  961. }
  962. var tokenRule []interface{}
  963. for _, tokenItem := range token {
  964. tokenRule = append(tokenRule, tokenItem)
  965. }
  966. logs, sub, err := _WithdrawalDelayer.contract.FilterLogs(opts, "EscapeHatchWithdrawal", whoRule, toRule, tokenRule)
  967. if err != nil {
  968. return nil, err
  969. }
  970. return &WithdrawalDelayerEscapeHatchWithdrawalIterator{contract: _WithdrawalDelayer.contract, event: "EscapeHatchWithdrawal", logs: logs, sub: sub}, nil
  971. }
  972. // WatchEscapeHatchWithdrawal is a free log subscription operation binding the contract event 0xde200220117ba95c9a6c4a1a13bb06b0b7be90faa85c8fb4576630119f891693.
  973. //
  974. // Solidity: event EscapeHatchWithdrawal(address indexed who, address indexed to, address indexed token, uint256 amount)
  975. func (_WithdrawalDelayer *WithdrawalDelayerFilterer) WatchEscapeHatchWithdrawal(opts *bind.WatchOpts, sink chan<- *WithdrawalDelayerEscapeHatchWithdrawal, who []common.Address, to []common.Address, token []common.Address) (event.Subscription, error) {
  976. var whoRule []interface{}
  977. for _, whoItem := range who {
  978. whoRule = append(whoRule, whoItem)
  979. }
  980. var toRule []interface{}
  981. for _, toItem := range to {
  982. toRule = append(toRule, toItem)
  983. }
  984. var tokenRule []interface{}
  985. for _, tokenItem := range token {
  986. tokenRule = append(tokenRule, tokenItem)
  987. }
  988. logs, sub, err := _WithdrawalDelayer.contract.WatchLogs(opts, "EscapeHatchWithdrawal", whoRule, toRule, tokenRule)
  989. if err != nil {
  990. return nil, err
  991. }
  992. return event.NewSubscription(func(quit <-chan struct{}) error {
  993. defer sub.Unsubscribe()
  994. for {
  995. select {
  996. case log := <-logs:
  997. // New log arrived, parse the event and forward to the user
  998. event := new(WithdrawalDelayerEscapeHatchWithdrawal)
  999. if err := _WithdrawalDelayer.contract.UnpackLog(event, "EscapeHatchWithdrawal", log); err != nil {
  1000. return err
  1001. }
  1002. event.Raw = log
  1003. select {
  1004. case sink <- event:
  1005. case err := <-sub.Err():
  1006. return err
  1007. case <-quit:
  1008. return nil
  1009. }
  1010. case err := <-sub.Err():
  1011. return err
  1012. case <-quit:
  1013. return nil
  1014. }
  1015. }
  1016. }), nil
  1017. }
  1018. // ParseEscapeHatchWithdrawal is a log parse operation binding the contract event 0xde200220117ba95c9a6c4a1a13bb06b0b7be90faa85c8fb4576630119f891693.
  1019. //
  1020. // Solidity: event EscapeHatchWithdrawal(address indexed who, address indexed to, address indexed token, uint256 amount)
  1021. func (_WithdrawalDelayer *WithdrawalDelayerFilterer) ParseEscapeHatchWithdrawal(log types.Log) (*WithdrawalDelayerEscapeHatchWithdrawal, error) {
  1022. event := new(WithdrawalDelayerEscapeHatchWithdrawal)
  1023. if err := _WithdrawalDelayer.contract.UnpackLog(event, "EscapeHatchWithdrawal", log); err != nil {
  1024. return nil, err
  1025. }
  1026. event.Raw = log
  1027. return event, nil
  1028. }
  1029. // WithdrawalDelayerInitializeWithdrawalDelayerEventIterator is returned from FilterInitializeWithdrawalDelayerEvent and is used to iterate over the raw logs and unpacked data for InitializeWithdrawalDelayerEvent events raised by the WithdrawalDelayer contract.
  1030. type WithdrawalDelayerInitializeWithdrawalDelayerEventIterator struct {
  1031. Event *WithdrawalDelayerInitializeWithdrawalDelayerEvent // Event containing the contract specifics and raw log
  1032. contract *bind.BoundContract // Generic contract to use for unpacking event data
  1033. event string // Event name to use for unpacking event data
  1034. logs chan types.Log // Log channel receiving the found contract events
  1035. sub ethereum.Subscription // Subscription for errors, completion and termination
  1036. done bool // Whether the subscription completed delivering logs
  1037. fail error // Occurred error to stop iteration
  1038. }
  1039. // Next advances the iterator to the subsequent event, returning whether there
  1040. // are any more events found. In case of a retrieval or parsing error, false is
  1041. // returned and Error() can be queried for the exact failure.
  1042. func (it *WithdrawalDelayerInitializeWithdrawalDelayerEventIterator) Next() bool {
  1043. // If the iterator failed, stop iterating
  1044. if it.fail != nil {
  1045. return false
  1046. }
  1047. // If the iterator completed, deliver directly whatever's available
  1048. if it.done {
  1049. select {
  1050. case log := <-it.logs:
  1051. it.Event = new(WithdrawalDelayerInitializeWithdrawalDelayerEvent)
  1052. if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
  1053. it.fail = err
  1054. return false
  1055. }
  1056. it.Event.Raw = log
  1057. return true
  1058. default:
  1059. return false
  1060. }
  1061. }
  1062. // Iterator still in progress, wait for either a data or an error event
  1063. select {
  1064. case log := <-it.logs:
  1065. it.Event = new(WithdrawalDelayerInitializeWithdrawalDelayerEvent)
  1066. if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
  1067. it.fail = err
  1068. return false
  1069. }
  1070. it.Event.Raw = log
  1071. return true
  1072. case err := <-it.sub.Err():
  1073. it.done = true
  1074. it.fail = err
  1075. return it.Next()
  1076. }
  1077. }
  1078. // Error returns any retrieval or parsing error occurred during filtering.
  1079. func (it *WithdrawalDelayerInitializeWithdrawalDelayerEventIterator) Error() error {
  1080. return it.fail
  1081. }
  1082. // Close terminates the iteration process, releasing any pending underlying
  1083. // resources.
  1084. func (it *WithdrawalDelayerInitializeWithdrawalDelayerEventIterator) Close() error {
  1085. it.sub.Unsubscribe()
  1086. return nil
  1087. }
  1088. // WithdrawalDelayerInitializeWithdrawalDelayerEvent represents a InitializeWithdrawalDelayerEvent event raised by the WithdrawalDelayer contract.
  1089. type WithdrawalDelayerInitializeWithdrawalDelayerEvent struct {
  1090. InitialWithdrawalDelay uint64
  1091. InitialHermezGovernanceAddress common.Address
  1092. InitialEmergencyCouncil common.Address
  1093. Raw types.Log // Blockchain specific contextual infos
  1094. }
  1095. // FilterInitializeWithdrawalDelayerEvent is a free log retrieval operation binding the contract event 0x8b81dca4c96ae06989fa8aa1baa4ccc05dfb42e0948c7d5b7505b68ccde41eec.
  1096. //
  1097. // Solidity: event InitializeWithdrawalDelayerEvent(uint64 initialWithdrawalDelay, address initialHermezGovernanceAddress, address initialEmergencyCouncil)
  1098. func (_WithdrawalDelayer *WithdrawalDelayerFilterer) FilterInitializeWithdrawalDelayerEvent(opts *bind.FilterOpts) (*WithdrawalDelayerInitializeWithdrawalDelayerEventIterator, error) {
  1099. logs, sub, err := _WithdrawalDelayer.contract.FilterLogs(opts, "InitializeWithdrawalDelayerEvent")
  1100. if err != nil {
  1101. return nil, err
  1102. }
  1103. return &WithdrawalDelayerInitializeWithdrawalDelayerEventIterator{contract: _WithdrawalDelayer.contract, event: "InitializeWithdrawalDelayerEvent", logs: logs, sub: sub}, nil
  1104. }
  1105. // WatchInitializeWithdrawalDelayerEvent is a free log subscription operation binding the contract event 0x8b81dca4c96ae06989fa8aa1baa4ccc05dfb42e0948c7d5b7505b68ccde41eec.
  1106. //
  1107. // Solidity: event InitializeWithdrawalDelayerEvent(uint64 initialWithdrawalDelay, address initialHermezGovernanceAddress, address initialEmergencyCouncil)
  1108. func (_WithdrawalDelayer *WithdrawalDelayerFilterer) WatchInitializeWithdrawalDelayerEvent(opts *bind.WatchOpts, sink chan<- *WithdrawalDelayerInitializeWithdrawalDelayerEvent) (event.Subscription, error) {
  1109. logs, sub, err := _WithdrawalDelayer.contract.WatchLogs(opts, "InitializeWithdrawalDelayerEvent")
  1110. if err != nil {
  1111. return nil, err
  1112. }
  1113. return event.NewSubscription(func(quit <-chan struct{}) error {
  1114. defer sub.Unsubscribe()
  1115. for {
  1116. select {
  1117. case log := <-logs:
  1118. // New log arrived, parse the event and forward to the user
  1119. event := new(WithdrawalDelayerInitializeWithdrawalDelayerEvent)
  1120. if err := _WithdrawalDelayer.contract.UnpackLog(event, "InitializeWithdrawalDelayerEvent", log); err != nil {
  1121. return err
  1122. }
  1123. event.Raw = log
  1124. select {
  1125. case sink <- event:
  1126. case err := <-sub.Err():
  1127. return err
  1128. case <-quit:
  1129. return nil
  1130. }
  1131. case err := <-sub.Err():
  1132. return err
  1133. case <-quit:
  1134. return nil
  1135. }
  1136. }
  1137. }), nil
  1138. }
  1139. // ParseInitializeWithdrawalDelayerEvent is a log parse operation binding the contract event 0x8b81dca4c96ae06989fa8aa1baa4ccc05dfb42e0948c7d5b7505b68ccde41eec.
  1140. //
  1141. // Solidity: event InitializeWithdrawalDelayerEvent(uint64 initialWithdrawalDelay, address initialHermezGovernanceAddress, address initialEmergencyCouncil)
  1142. func (_WithdrawalDelayer *WithdrawalDelayerFilterer) ParseInitializeWithdrawalDelayerEvent(log types.Log) (*WithdrawalDelayerInitializeWithdrawalDelayerEvent, error) {
  1143. event := new(WithdrawalDelayerInitializeWithdrawalDelayerEvent)
  1144. if err := _WithdrawalDelayer.contract.UnpackLog(event, "InitializeWithdrawalDelayerEvent", log); err != nil {
  1145. return nil, err
  1146. }
  1147. event.Raw = log
  1148. return event, nil
  1149. }
  1150. // WithdrawalDelayerNewEmergencyCouncilIterator is returned from FilterNewEmergencyCouncil and is used to iterate over the raw logs and unpacked data for NewEmergencyCouncil events raised by the WithdrawalDelayer contract.
  1151. type WithdrawalDelayerNewEmergencyCouncilIterator struct {
  1152. Event *WithdrawalDelayerNewEmergencyCouncil // Event containing the contract specifics and raw log
  1153. contract *bind.BoundContract // Generic contract to use for unpacking event data
  1154. event string // Event name to use for unpacking event data
  1155. logs chan types.Log // Log channel receiving the found contract events
  1156. sub ethereum.Subscription // Subscription for errors, completion and termination
  1157. done bool // Whether the subscription completed delivering logs
  1158. fail error // Occurred error to stop iteration
  1159. }
  1160. // Next advances the iterator to the subsequent event, returning whether there
  1161. // are any more events found. In case of a retrieval or parsing error, false is
  1162. // returned and Error() can be queried for the exact failure.
  1163. func (it *WithdrawalDelayerNewEmergencyCouncilIterator) Next() bool {
  1164. // If the iterator failed, stop iterating
  1165. if it.fail != nil {
  1166. return false
  1167. }
  1168. // If the iterator completed, deliver directly whatever's available
  1169. if it.done {
  1170. select {
  1171. case log := <-it.logs:
  1172. it.Event = new(WithdrawalDelayerNewEmergencyCouncil)
  1173. if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
  1174. it.fail = err
  1175. return false
  1176. }
  1177. it.Event.Raw = log
  1178. return true
  1179. default:
  1180. return false
  1181. }
  1182. }
  1183. // Iterator still in progress, wait for either a data or an error event
  1184. select {
  1185. case log := <-it.logs:
  1186. it.Event = new(WithdrawalDelayerNewEmergencyCouncil)
  1187. if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
  1188. it.fail = err
  1189. return false
  1190. }
  1191. it.Event.Raw = log
  1192. return true
  1193. case err := <-it.sub.Err():
  1194. it.done = true
  1195. it.fail = err
  1196. return it.Next()
  1197. }
  1198. }
  1199. // Error returns any retrieval or parsing error occurred during filtering.
  1200. func (it *WithdrawalDelayerNewEmergencyCouncilIterator) Error() error {
  1201. return it.fail
  1202. }
  1203. // Close terminates the iteration process, releasing any pending underlying
  1204. // resources.
  1205. func (it *WithdrawalDelayerNewEmergencyCouncilIterator) Close() error {
  1206. it.sub.Unsubscribe()
  1207. return nil
  1208. }
  1209. // WithdrawalDelayerNewEmergencyCouncil represents a NewEmergencyCouncil event raised by the WithdrawalDelayer contract.
  1210. type WithdrawalDelayerNewEmergencyCouncil struct {
  1211. NewEmergencyCouncil common.Address
  1212. Raw types.Log // Blockchain specific contextual infos
  1213. }
  1214. // FilterNewEmergencyCouncil is a free log retrieval operation binding the contract event 0xcc267667d474ef34ee2de2d060e7c8b2c7295cefa22e57fd7049e22b5fdb5396.
  1215. //
  1216. // Solidity: event NewEmergencyCouncil(address newEmergencyCouncil)
  1217. func (_WithdrawalDelayer *WithdrawalDelayerFilterer) FilterNewEmergencyCouncil(opts *bind.FilterOpts) (*WithdrawalDelayerNewEmergencyCouncilIterator, error) {
  1218. logs, sub, err := _WithdrawalDelayer.contract.FilterLogs(opts, "NewEmergencyCouncil")
  1219. if err != nil {
  1220. return nil, err
  1221. }
  1222. return &WithdrawalDelayerNewEmergencyCouncilIterator{contract: _WithdrawalDelayer.contract, event: "NewEmergencyCouncil", logs: logs, sub: sub}, nil
  1223. }
  1224. // WatchNewEmergencyCouncil is a free log subscription operation binding the contract event 0xcc267667d474ef34ee2de2d060e7c8b2c7295cefa22e57fd7049e22b5fdb5396.
  1225. //
  1226. // Solidity: event NewEmergencyCouncil(address newEmergencyCouncil)
  1227. func (_WithdrawalDelayer *WithdrawalDelayerFilterer) WatchNewEmergencyCouncil(opts *bind.WatchOpts, sink chan<- *WithdrawalDelayerNewEmergencyCouncil) (event.Subscription, error) {
  1228. logs, sub, err := _WithdrawalDelayer.contract.WatchLogs(opts, "NewEmergencyCouncil")
  1229. if err != nil {
  1230. return nil, err
  1231. }
  1232. return event.NewSubscription(func(quit <-chan struct{}) error {
  1233. defer sub.Unsubscribe()
  1234. for {
  1235. select {
  1236. case log := <-logs:
  1237. // New log arrived, parse the event and forward to the user
  1238. event := new(WithdrawalDelayerNewEmergencyCouncil)
  1239. if err := _WithdrawalDelayer.contract.UnpackLog(event, "NewEmergencyCouncil", log); err != nil {
  1240. return err
  1241. }
  1242. event.Raw = log
  1243. select {
  1244. case sink <- event:
  1245. case err := <-sub.Err():
  1246. return err
  1247. case <-quit:
  1248. return nil
  1249. }
  1250. case err := <-sub.Err():
  1251. return err
  1252. case <-quit:
  1253. return nil
  1254. }
  1255. }
  1256. }), nil
  1257. }
  1258. // ParseNewEmergencyCouncil is a log parse operation binding the contract event 0xcc267667d474ef34ee2de2d060e7c8b2c7295cefa22e57fd7049e22b5fdb5396.
  1259. //
  1260. // Solidity: event NewEmergencyCouncil(address newEmergencyCouncil)
  1261. func (_WithdrawalDelayer *WithdrawalDelayerFilterer) ParseNewEmergencyCouncil(log types.Log) (*WithdrawalDelayerNewEmergencyCouncil, error) {
  1262. event := new(WithdrawalDelayerNewEmergencyCouncil)
  1263. if err := _WithdrawalDelayer.contract.UnpackLog(event, "NewEmergencyCouncil", log); err != nil {
  1264. return nil, err
  1265. }
  1266. event.Raw = log
  1267. return event, nil
  1268. }
  1269. // WithdrawalDelayerNewHermezGovernanceAddressIterator is returned from FilterNewHermezGovernanceAddress and is used to iterate over the raw logs and unpacked data for NewHermezGovernanceAddress events raised by the WithdrawalDelayer contract.
  1270. type WithdrawalDelayerNewHermezGovernanceAddressIterator struct {
  1271. Event *WithdrawalDelayerNewHermezGovernanceAddress // Event containing the contract specifics and raw log
  1272. contract *bind.BoundContract // Generic contract to use for unpacking event data
  1273. event string // Event name to use for unpacking event data
  1274. logs chan types.Log // Log channel receiving the found contract events
  1275. sub ethereum.Subscription // Subscription for errors, completion and termination
  1276. done bool // Whether the subscription completed delivering logs
  1277. fail error // Occurred error to stop iteration
  1278. }
  1279. // Next advances the iterator to the subsequent event, returning whether there
  1280. // are any more events found. In case of a retrieval or parsing error, false is
  1281. // returned and Error() can be queried for the exact failure.
  1282. func (it *WithdrawalDelayerNewHermezGovernanceAddressIterator) Next() bool {
  1283. // If the iterator failed, stop iterating
  1284. if it.fail != nil {
  1285. return false
  1286. }
  1287. // If the iterator completed, deliver directly whatever's available
  1288. if it.done {
  1289. select {
  1290. case log := <-it.logs:
  1291. it.Event = new(WithdrawalDelayerNewHermezGovernanceAddress)
  1292. if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
  1293. it.fail = err
  1294. return false
  1295. }
  1296. it.Event.Raw = log
  1297. return true
  1298. default:
  1299. return false
  1300. }
  1301. }
  1302. // Iterator still in progress, wait for either a data or an error event
  1303. select {
  1304. case log := <-it.logs:
  1305. it.Event = new(WithdrawalDelayerNewHermezGovernanceAddress)
  1306. if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
  1307. it.fail = err
  1308. return false
  1309. }
  1310. it.Event.Raw = log
  1311. return true
  1312. case err := <-it.sub.Err():
  1313. it.done = true
  1314. it.fail = err
  1315. return it.Next()
  1316. }
  1317. }
  1318. // Error returns any retrieval or parsing error occurred during filtering.
  1319. func (it *WithdrawalDelayerNewHermezGovernanceAddressIterator) Error() error {
  1320. return it.fail
  1321. }
  1322. // Close terminates the iteration process, releasing any pending underlying
  1323. // resources.
  1324. func (it *WithdrawalDelayerNewHermezGovernanceAddressIterator) Close() error {
  1325. it.sub.Unsubscribe()
  1326. return nil
  1327. }
  1328. // WithdrawalDelayerNewHermezGovernanceAddress represents a NewHermezGovernanceAddress event raised by the WithdrawalDelayer contract.
  1329. type WithdrawalDelayerNewHermezGovernanceAddress struct {
  1330. NewHermezGovernanceAddress common.Address
  1331. Raw types.Log // Blockchain specific contextual infos
  1332. }
  1333. // FilterNewHermezGovernanceAddress is a free log retrieval operation binding the contract event 0x3bf02437d5cd40067085d9dac2c3cdcbef0a449d98a259a40d9c24380aca81bf.
  1334. //
  1335. // Solidity: event NewHermezGovernanceAddress(address newHermezGovernanceAddress)
  1336. func (_WithdrawalDelayer *WithdrawalDelayerFilterer) FilterNewHermezGovernanceAddress(opts *bind.FilterOpts) (*WithdrawalDelayerNewHermezGovernanceAddressIterator, error) {
  1337. logs, sub, err := _WithdrawalDelayer.contract.FilterLogs(opts, "NewHermezGovernanceAddress")
  1338. if err != nil {
  1339. return nil, err
  1340. }
  1341. return &WithdrawalDelayerNewHermezGovernanceAddressIterator{contract: _WithdrawalDelayer.contract, event: "NewHermezGovernanceAddress", logs: logs, sub: sub}, nil
  1342. }
  1343. // WatchNewHermezGovernanceAddress is a free log subscription operation binding the contract event 0x3bf02437d5cd40067085d9dac2c3cdcbef0a449d98a259a40d9c24380aca81bf.
  1344. //
  1345. // Solidity: event NewHermezGovernanceAddress(address newHermezGovernanceAddress)
  1346. func (_WithdrawalDelayer *WithdrawalDelayerFilterer) WatchNewHermezGovernanceAddress(opts *bind.WatchOpts, sink chan<- *WithdrawalDelayerNewHermezGovernanceAddress) (event.Subscription, error) {
  1347. logs, sub, err := _WithdrawalDelayer.contract.WatchLogs(opts, "NewHermezGovernanceAddress")
  1348. if err != nil {
  1349. return nil, err
  1350. }
  1351. return event.NewSubscription(func(quit <-chan struct{}) error {
  1352. defer sub.Unsubscribe()
  1353. for {
  1354. select {
  1355. case log := <-logs:
  1356. // New log arrived, parse the event and forward to the user
  1357. event := new(WithdrawalDelayerNewHermezGovernanceAddress)
  1358. if err := _WithdrawalDelayer.contract.UnpackLog(event, "NewHermezGovernanceAddress", log); err != nil {
  1359. return err
  1360. }
  1361. event.Raw = log
  1362. select {
  1363. case sink <- event:
  1364. case err := <-sub.Err():
  1365. return err
  1366. case <-quit:
  1367. return nil
  1368. }
  1369. case err := <-sub.Err():
  1370. return err
  1371. case <-quit:
  1372. return nil
  1373. }
  1374. }
  1375. }), nil
  1376. }
  1377. // ParseNewHermezGovernanceAddress is a log parse operation binding the contract event 0x3bf02437d5cd40067085d9dac2c3cdcbef0a449d98a259a40d9c24380aca81bf.
  1378. //
  1379. // Solidity: event NewHermezGovernanceAddress(address newHermezGovernanceAddress)
  1380. func (_WithdrawalDelayer *WithdrawalDelayerFilterer) ParseNewHermezGovernanceAddress(log types.Log) (*WithdrawalDelayerNewHermezGovernanceAddress, error) {
  1381. event := new(WithdrawalDelayerNewHermezGovernanceAddress)
  1382. if err := _WithdrawalDelayer.contract.UnpackLog(event, "NewHermezGovernanceAddress", log); err != nil {
  1383. return nil, err
  1384. }
  1385. event.Raw = log
  1386. return event, nil
  1387. }
  1388. // WithdrawalDelayerNewWithdrawalDelayIterator is returned from FilterNewWithdrawalDelay and is used to iterate over the raw logs and unpacked data for NewWithdrawalDelay events raised by the WithdrawalDelayer contract.
  1389. type WithdrawalDelayerNewWithdrawalDelayIterator struct {
  1390. Event *WithdrawalDelayerNewWithdrawalDelay // Event containing the contract specifics and raw log
  1391. contract *bind.BoundContract // Generic contract to use for unpacking event data
  1392. event string // Event name to use for unpacking event data
  1393. logs chan types.Log // Log channel receiving the found contract events
  1394. sub ethereum.Subscription // Subscription for errors, completion and termination
  1395. done bool // Whether the subscription completed delivering logs
  1396. fail error // Occurred error to stop iteration
  1397. }
  1398. // Next advances the iterator to the subsequent event, returning whether there
  1399. // are any more events found. In case of a retrieval or parsing error, false is
  1400. // returned and Error() can be queried for the exact failure.
  1401. func (it *WithdrawalDelayerNewWithdrawalDelayIterator) Next() bool {
  1402. // If the iterator failed, stop iterating
  1403. if it.fail != nil {
  1404. return false
  1405. }
  1406. // If the iterator completed, deliver directly whatever's available
  1407. if it.done {
  1408. select {
  1409. case log := <-it.logs:
  1410. it.Event = new(WithdrawalDelayerNewWithdrawalDelay)
  1411. if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
  1412. it.fail = err
  1413. return false
  1414. }
  1415. it.Event.Raw = log
  1416. return true
  1417. default:
  1418. return false
  1419. }
  1420. }
  1421. // Iterator still in progress, wait for either a data or an error event
  1422. select {
  1423. case log := <-it.logs:
  1424. it.Event = new(WithdrawalDelayerNewWithdrawalDelay)
  1425. if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
  1426. it.fail = err
  1427. return false
  1428. }
  1429. it.Event.Raw = log
  1430. return true
  1431. case err := <-it.sub.Err():
  1432. it.done = true
  1433. it.fail = err
  1434. return it.Next()
  1435. }
  1436. }
  1437. // Error returns any retrieval or parsing error occurred during filtering.
  1438. func (it *WithdrawalDelayerNewWithdrawalDelayIterator) Error() error {
  1439. return it.fail
  1440. }
  1441. // Close terminates the iteration process, releasing any pending underlying
  1442. // resources.
  1443. func (it *WithdrawalDelayerNewWithdrawalDelayIterator) Close() error {
  1444. it.sub.Unsubscribe()
  1445. return nil
  1446. }
  1447. // WithdrawalDelayerNewWithdrawalDelay represents a NewWithdrawalDelay event raised by the WithdrawalDelayer contract.
  1448. type WithdrawalDelayerNewWithdrawalDelay struct {
  1449. WithdrawalDelay uint64
  1450. Raw types.Log // Blockchain specific contextual infos
  1451. }
  1452. // FilterNewWithdrawalDelay is a free log retrieval operation binding the contract event 0x6b3670ab51e04a9da086741e5fd1eb36ffaf1d661a15330c528e1f3e0c8722d7.
  1453. //
  1454. // Solidity: event NewWithdrawalDelay(uint64 withdrawalDelay)
  1455. func (_WithdrawalDelayer *WithdrawalDelayerFilterer) FilterNewWithdrawalDelay(opts *bind.FilterOpts) (*WithdrawalDelayerNewWithdrawalDelayIterator, error) {
  1456. logs, sub, err := _WithdrawalDelayer.contract.FilterLogs(opts, "NewWithdrawalDelay")
  1457. if err != nil {
  1458. return nil, err
  1459. }
  1460. return &WithdrawalDelayerNewWithdrawalDelayIterator{contract: _WithdrawalDelayer.contract, event: "NewWithdrawalDelay", logs: logs, sub: sub}, nil
  1461. }
  1462. // WatchNewWithdrawalDelay is a free log subscription operation binding the contract event 0x6b3670ab51e04a9da086741e5fd1eb36ffaf1d661a15330c528e1f3e0c8722d7.
  1463. //
  1464. // Solidity: event NewWithdrawalDelay(uint64 withdrawalDelay)
  1465. func (_WithdrawalDelayer *WithdrawalDelayerFilterer) WatchNewWithdrawalDelay(opts *bind.WatchOpts, sink chan<- *WithdrawalDelayerNewWithdrawalDelay) (event.Subscription, error) {
  1466. logs, sub, err := _WithdrawalDelayer.contract.WatchLogs(opts, "NewWithdrawalDelay")
  1467. if err != nil {
  1468. return nil, err
  1469. }
  1470. return event.NewSubscription(func(quit <-chan struct{}) error {
  1471. defer sub.Unsubscribe()
  1472. for {
  1473. select {
  1474. case log := <-logs:
  1475. // New log arrived, parse the event and forward to the user
  1476. event := new(WithdrawalDelayerNewWithdrawalDelay)
  1477. if err := _WithdrawalDelayer.contract.UnpackLog(event, "NewWithdrawalDelay", log); err != nil {
  1478. return err
  1479. }
  1480. event.Raw = log
  1481. select {
  1482. case sink <- event:
  1483. case err := <-sub.Err():
  1484. return err
  1485. case <-quit:
  1486. return nil
  1487. }
  1488. case err := <-sub.Err():
  1489. return err
  1490. case <-quit:
  1491. return nil
  1492. }
  1493. }
  1494. }), nil
  1495. }
  1496. // ParseNewWithdrawalDelay is a log parse operation binding the contract event 0x6b3670ab51e04a9da086741e5fd1eb36ffaf1d661a15330c528e1f3e0c8722d7.
  1497. //
  1498. // Solidity: event NewWithdrawalDelay(uint64 withdrawalDelay)
  1499. func (_WithdrawalDelayer *WithdrawalDelayerFilterer) ParseNewWithdrawalDelay(log types.Log) (*WithdrawalDelayerNewWithdrawalDelay, error) {
  1500. event := new(WithdrawalDelayerNewWithdrawalDelay)
  1501. if err := _WithdrawalDelayer.contract.UnpackLog(event, "NewWithdrawalDelay", log); err != nil {
  1502. return nil, err
  1503. }
  1504. event.Raw = log
  1505. return event, nil
  1506. }
  1507. // WithdrawalDelayerWithdrawIterator is returned from FilterWithdraw and is used to iterate over the raw logs and unpacked data for Withdraw events raised by the WithdrawalDelayer contract.
  1508. type WithdrawalDelayerWithdrawIterator struct {
  1509. Event *WithdrawalDelayerWithdraw // Event containing the contract specifics and raw log
  1510. contract *bind.BoundContract // Generic contract to use for unpacking event data
  1511. event string // Event name to use for unpacking event data
  1512. logs chan types.Log // Log channel receiving the found contract events
  1513. sub ethereum.Subscription // Subscription for errors, completion and termination
  1514. done bool // Whether the subscription completed delivering logs
  1515. fail error // Occurred error to stop iteration
  1516. }
  1517. // Next advances the iterator to the subsequent event, returning whether there
  1518. // are any more events found. In case of a retrieval or parsing error, false is
  1519. // returned and Error() can be queried for the exact failure.
  1520. func (it *WithdrawalDelayerWithdrawIterator) Next() bool {
  1521. // If the iterator failed, stop iterating
  1522. if it.fail != nil {
  1523. return false
  1524. }
  1525. // If the iterator completed, deliver directly whatever's available
  1526. if it.done {
  1527. select {
  1528. case log := <-it.logs:
  1529. it.Event = new(WithdrawalDelayerWithdraw)
  1530. if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
  1531. it.fail = err
  1532. return false
  1533. }
  1534. it.Event.Raw = log
  1535. return true
  1536. default:
  1537. return false
  1538. }
  1539. }
  1540. // Iterator still in progress, wait for either a data or an error event
  1541. select {
  1542. case log := <-it.logs:
  1543. it.Event = new(WithdrawalDelayerWithdraw)
  1544. if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
  1545. it.fail = err
  1546. return false
  1547. }
  1548. it.Event.Raw = log
  1549. return true
  1550. case err := <-it.sub.Err():
  1551. it.done = true
  1552. it.fail = err
  1553. return it.Next()
  1554. }
  1555. }
  1556. // Error returns any retrieval or parsing error occurred during filtering.
  1557. func (it *WithdrawalDelayerWithdrawIterator) Error() error {
  1558. return it.fail
  1559. }
  1560. // Close terminates the iteration process, releasing any pending underlying
  1561. // resources.
  1562. func (it *WithdrawalDelayerWithdrawIterator) Close() error {
  1563. it.sub.Unsubscribe()
  1564. return nil
  1565. }
  1566. // WithdrawalDelayerWithdraw represents a Withdraw event raised by the WithdrawalDelayer contract.
  1567. type WithdrawalDelayerWithdraw struct {
  1568. Token common.Address
  1569. Owner common.Address
  1570. Amount *big.Int
  1571. Raw types.Log // Blockchain specific contextual infos
  1572. }
  1573. // FilterWithdraw is a free log retrieval operation binding the contract event 0x72608e45b52a95a12c2ac7f15ff53f92fc9572c9d84b6e6b5d7f0f7826cf3271.
  1574. //
  1575. // Solidity: event Withdraw(address indexed token, address indexed owner, uint192 amount)
  1576. func (_WithdrawalDelayer *WithdrawalDelayerFilterer) FilterWithdraw(opts *bind.FilterOpts, token []common.Address, owner []common.Address) (*WithdrawalDelayerWithdrawIterator, error) {
  1577. var tokenRule []interface{}
  1578. for _, tokenItem := range token {
  1579. tokenRule = append(tokenRule, tokenItem)
  1580. }
  1581. var ownerRule []interface{}
  1582. for _, ownerItem := range owner {
  1583. ownerRule = append(ownerRule, ownerItem)
  1584. }
  1585. logs, sub, err := _WithdrawalDelayer.contract.FilterLogs(opts, "Withdraw", tokenRule, ownerRule)
  1586. if err != nil {
  1587. return nil, err
  1588. }
  1589. return &WithdrawalDelayerWithdrawIterator{contract: _WithdrawalDelayer.contract, event: "Withdraw", logs: logs, sub: sub}, nil
  1590. }
  1591. // WatchWithdraw is a free log subscription operation binding the contract event 0x72608e45b52a95a12c2ac7f15ff53f92fc9572c9d84b6e6b5d7f0f7826cf3271.
  1592. //
  1593. // Solidity: event Withdraw(address indexed token, address indexed owner, uint192 amount)
  1594. func (_WithdrawalDelayer *WithdrawalDelayerFilterer) WatchWithdraw(opts *bind.WatchOpts, sink chan<- *WithdrawalDelayerWithdraw, token []common.Address, owner []common.Address) (event.Subscription, error) {
  1595. var tokenRule []interface{}
  1596. for _, tokenItem := range token {
  1597. tokenRule = append(tokenRule, tokenItem)
  1598. }
  1599. var ownerRule []interface{}
  1600. for _, ownerItem := range owner {
  1601. ownerRule = append(ownerRule, ownerItem)
  1602. }
  1603. logs, sub, err := _WithdrawalDelayer.contract.WatchLogs(opts, "Withdraw", tokenRule, ownerRule)
  1604. if err != nil {
  1605. return nil, err
  1606. }
  1607. return event.NewSubscription(func(quit <-chan struct{}) error {
  1608. defer sub.Unsubscribe()
  1609. for {
  1610. select {
  1611. case log := <-logs:
  1612. // New log arrived, parse the event and forward to the user
  1613. event := new(WithdrawalDelayerWithdraw)
  1614. if err := _WithdrawalDelayer.contract.UnpackLog(event, "Withdraw", log); err != nil {
  1615. return err
  1616. }
  1617. event.Raw = log
  1618. select {
  1619. case sink <- event:
  1620. case err := <-sub.Err():
  1621. return err
  1622. case <-quit:
  1623. return nil
  1624. }
  1625. case err := <-sub.Err():
  1626. return err
  1627. case <-quit:
  1628. return nil
  1629. }
  1630. }
  1631. }), nil
  1632. }
  1633. // ParseWithdraw is a log parse operation binding the contract event 0x72608e45b52a95a12c2ac7f15ff53f92fc9572c9d84b6e6b5d7f0f7826cf3271.
  1634. //
  1635. // Solidity: event Withdraw(address indexed token, address indexed owner, uint192 amount)
  1636. func (_WithdrawalDelayer *WithdrawalDelayerFilterer) ParseWithdraw(log types.Log) (*WithdrawalDelayerWithdraw, error) {
  1637. event := new(WithdrawalDelayerWithdraw)
  1638. if err := _WithdrawalDelayer.contract.UnpackLog(event, "Withdraw", log); err != nil {
  1639. return nil, err
  1640. }
  1641. event.Raw = log
  1642. return event, nil
  1643. }