pub struct Validator {
pub address: String,
pub owner: String,
pub stake: Hnt,
pub last_heartbeat: u64,
pub version_heartbeat: u64,
pub stake_status: String,
pub penalty: f64,
pub penalties: Vec<Penalty>,
pub block_added: u64,
pub block: u64,
}
Expand description
Represents a validator on the blockchain.
Fields§
§address: String
The validator address is the base58 check-encoded public key of the validator.
owner: String
The validator pwner is the base58 check-encoded public key of the owner of the validator.
stake: Hnt
The staked amount for the validator
last_heartbeat: u64
The last heartbeat transaction of the validator
version_heartbeat: u64
The last heartbeat version of the validator heartbeat
stake_status: String
The current status of the validator (staked, cooldown, unstaked)
penalty: f64
The total penalty of the validator
penalties: Vec<Penalty>
A list of penalties this validator has received
block_added: u64
The block this validator was added to chain
block: u64
The current block this validator is synced to
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Validator
impl<'de> Deserialize<'de> for Validator
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for Validator
impl RefUnwindSafe for Validator
impl Send for Validator
impl Sync for Validator
impl Unpin for Validator
impl UnwindSafe for Validator
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more