Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ForkBit is set if staker has a confirmed pair of fork events ForkBit = uint64(1) // OfflineBit is set if staker has didn't have confirmed events for a long time OfflineBit = uint64(1 << 8) // CheaterMask is a combination of severe misbehavings CheaterMask = ForkBit )
Functions ¶
Types ¶
type EpochStats ¶
type EpochStats struct { Start inter.Timestamp End inter.Timestamp TotalFee *big.Int Epoch idx.Epoch `rlp:"-"` // API-only field TotalBaseRewardWeight *big.Int `rlp:"-"` // API-only field TotalTxRewardWeight *big.Int `rlp:"-"` // API-only field }
EpochStats stores general statistics for an epoch
func (*EpochStats) Duration ¶
func (s *EpochStats) Duration() inter.Timestamp
Duration returns epoch duration
type SfcDelegator ¶
type SfcDelegator struct { CreatedEpoch idx.Epoch CreatedTime inter.Timestamp DeactivatedEpoch idx.Epoch DeactivatedTime inter.Timestamp Amount *big.Int ToStakerID idx.StakerID }
SfcDelegator is the node-side representation of SFC delegator
type SfcDelegatorAndAddr ¶
type SfcDelegatorAndAddr struct { Delegator *SfcDelegator Addr common.Address }
SfcDelegatorAndAddr is pair SfcDelegator + address
type SfcStaker ¶
type SfcStaker struct { CreatedEpoch idx.Epoch CreatedTime inter.Timestamp DeactivatedEpoch idx.Epoch DeactivatedTime inter.Timestamp StakeAmount *big.Int DelegatedMe *big.Int Address common.Address Status uint64 IsValidator bool `rlp:"-"` // API-only field }
SfcStaker is the node-side representation of SFC staker
func (*SfcStaker) CalcTotalStake ¶
CalcTotalStake returns sum of staker's stake and delegated to staker stake
type SfcStakerAndID ¶
SfcStakerAndID is pair SfcStaker + StakerID
Click to show internal directories.
Click to hide internal directories.