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.

31 lines
1.5 KiB

  1. package common
  2. import ethCommon "github.com/ethereum/go-ethereum/common"
  3. // WDelayerConstants are the constants of the Withdrawal Delayer Smart Contract
  4. type WDelayerConstants struct {
  5. // Max Withdrawal Delay
  6. MaxWithdrawalDelay uint64 `json:"maxWithdrawalDelay"`
  7. // Max Emergency mode time
  8. MaxEmergencyModeTime uint64 `json:"maxEmergencyModeTime"`
  9. // HermezRollup smartcontract address
  10. HermezRollup ethCommon.Address `json:"hermezRollup"`
  11. }
  12. // WDelayerVariables are the variables of the Withdrawal Delayer Smart Contract
  13. type WDelayerVariables struct {
  14. EthBlockNum int64 `json:"ethereumBlockNum" meddler:"eth_block_num"`
  15. // HermezRollupAddress ethCommon.Address `json:"hermezRollupAddress" meddler:"rollup_address"`
  16. HermezGovernanceDAOAddress ethCommon.Address `json:"hermezGovernanceDAOAddress" meddler:"govdao_address" validate:"required"`
  17. WhiteHackGroupAddress ethCommon.Address `json:"whiteHackGroupAddress" meddler:"whg_address" validate:"required"`
  18. HermezKeeperAddress ethCommon.Address `json:"hermezKeeperAddress" meddler:"keeper_address" validate:"required"`
  19. WithdrawalDelay uint64 `json:"withdrawalDelay" meddler:"withdrawal_delay" validate:"required"`
  20. EmergencyModeStartingTime uint64 `json:"emergencyModeStartingTime" meddler:"emergency_start_time"`
  21. EmergencyMode bool `json:"emergencyMode" meddler:"emergency_mode"`
  22. }
  23. // Copy returns a deep copy of the Variables
  24. func (v *WDelayerVariables) Copy() *WDelayerVariables {
  25. vCpy := *v
  26. return &vCpy
  27. }