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.

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