Struct diem_types::validator_info::ValidatorInfo [−][src]
pub struct ValidatorInfo { /* fields omitted */ }
Expand description
After executing a special transaction indicates a change to the next epoch, consensus and networking get the new list of validators, their keys, and their voting power. Consensus has a public key to validate signed messages and networking will has public identity keys for creating secure channels of communication between validators. The validators and their public keys and voting power may or may not change between epochs.
Implementations
pub fn new(
account_address: AccountAddress,
consensus_voting_power: u64,
config: ValidatorConfig
) -> Self
Returns the id of this validator (hash of the current public key of the validator associated account address)
Returns the key for validating signed messages from this validator
Returns the voting power for this validator
Returns the validator’s config
Returns the validator’s config, consuming self
Trait Implementations
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
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
This method tests for !=
.
Auto Trait Implementations
impl RefUnwindSafe for ValidatorInfo
impl Send for ValidatorInfo
impl Sync for ValidatorInfo
impl Unpin for ValidatorInfo
impl UnwindSafe for ValidatorInfo
Blanket Implementations
Mutably borrows from an owned value. Read more
Generates a hash used only for tests.