Hord ETH Staking Manager (HETH)
Core contract for Ethereum Staking Platform.
Code
HordETHStakingManager.sol
Address
HordETHStakingManager
is deployed at 0x5bBe36152d3CD3eB7183A82470b39b29EedF068B
on the Ethereum mainnet.
Overview
HordETHStakingManager(HETH)
is upgradeable contract where users can deposit ETH in order to stake and earn validator rewards, redeeming of deposit is not possible yet, but it will be after the Shanghai Hard Fork.
Events
Deposit
Emitted each time when someone deposits.
LaunchNewValidator
Emitted each time when a new validator is launched.
HETHMinted
Emitted each time when new HETH tokens are minted.
EtherReceived
Emitted each time when contract receives the execution layer rewards.
FeeCollected
Emitted each time when reward fees are collected.
StakingStatsUpdated
Emitted each time when the staking stats are updated.
NewTokensFarmSDKSet
Emitted each time when the
TokensFarmSDK
address changes.
Transfer
Emitted each time when the someone transfers
HETH
tokens.
Approval
Emitted each time when the someone approves
HETH
tokens.
Burn
Emitted each time when HordETHStakingManager calls burn function.
Mint
Emitted each time when HordETHStakingManager calls mint function.
Core functions
userDepositETH
UserDepositETH
function allowing user to deposit ETH on contract.Emits
Deposit
event.
launchNewValidator
LaunchNewValidator
Withdraws funds for launching new validator, callable only by maintainer.Emits
LaunchNewValidator
event.
transfer
Transfer HETH from msg.sender to
recipient
address.Emits
Transfer
event.
approve
Msg.sender approves
spender
to manage his HETH tokens.Emits
Approval
event.
transferFrom
Transfer this
amount
of HETH fromsender
torecipient
address.Emits
Transfer
event.
Read-Only functions
totalETHDeposited
TotalETHDeposited
represents total ETH deposited by user.
totalBalanceETHInValidators
TotalBalanceETHInValidators
represents total balance ETH in validators includes amount required to launch the validator plus validator rewards.
totalRewardsCollected
TotalRewardsCollected
represents total rewards collected validator plus execution layer rewards.
totalHETHMinted
TotalHETHMinted
represents total HETH minted.
numberOfUsers
NumberOfUsers
represents total number of users who stake.
lastRewardsForFeeCalc
LastRewardsForFeeCalc
represents the last amount of total rewards from which fees was taken.
totalFeesAccountedInETH
TotalFeesAccountedInETH
represents total fees accounted in ETH.
totalFeesMintedInHETH
TotalFeesMintedInHETH
represents total fees minted in HETH.
lastExecLayerRewardsForFeeCalc
LastExecLayerRewardsForFeeCalc
represents the last amount of execution layer rewards from which fees was taken.
totalExecLayerRewards
TotalExecLayerRewards
represents total total amount of execution layer rewards.
hordCongressMembersRegistry
HordCongressMembersRegistry
represents instance of HordCongressMembersRegistry contract.
beaconDeposit
BeaconDeposit
represents instance of BeaconDeposit contract.
stakingConfiguration
StakingConfiguration
represents instance of StakingConfiguration contract.
users
Users
map user address to his informations.
getAmountOfHETHforETH
GetAmountOfHETHforETH
calculates how much HETH will be minted for certain amount of ETH.
decimals
decimals
returns the number of decimals used to get its user representation.
totalSupply
totalSuplly
returns total supply of HETH token.
balanceOf
balanceOf
balance of HETH tokens for sepcificaccount
.
allowance
allowance
returns amount of HETH whichowner
has approvedspender
to use.
name
name
returns name of HETH token.
symbol
symbol
returns symbol of HETH token.
State-Changing Functions
pause
Pause
function allowing HordCongress or maintainer to pause contract.Emits
Paused
event.
unpause
Unpause
function allowing HordCongress member to unpause contract.Emits
Unpaused
event.
setTokensfarmSDK
SetTokensFarmSDK
sets address of TokensFarmSDK contract.Emits a
NewTokensFarmSDKSet
ecent.
setValidatorStats
SetValidatorStats
sets total amount of collected rewards, total balance ETH in validators and total amount of execution layer rewards.Emits a
StakingStatsUpdated
event.
Last updated