Struct ethjson::spec::authority_round::AuthorityRoundParams
source · [−]pub struct AuthorityRoundParams {Show 21 fields
pub step_duration: StepDuration,
pub validators: ValidatorSet,
pub start_step: Option<Uint>,
pub validate_score_transition: Option<Uint>,
pub validate_step_transition: Option<Uint>,
pub immediate_transitions: Option<bool>,
pub block_reward: Option<BlockReward>,
pub block_reward_contract_transition: Option<Uint>,
pub block_reward_contract_address: Option<Address>,
pub block_reward_contract_transitions: Option<BTreeMap<Uint, Address>>,
pub block_reward_contract_code: Option<Bytes>,
pub maximum_uncle_count_transition: Option<Uint>,
pub maximum_uncle_count: Option<Uint>,
pub empty_steps_transition: Option<Uint>,
pub maximum_empty_steps: Option<Uint>,
pub strict_empty_steps_transition: Option<Uint>,
pub two_thirds_majority_transition: Option<Uint>,
pub randomness_contract_address: Option<BTreeMap<Uint, Address>>,
pub block_gas_limit_contract_transitions: Option<BTreeMap<Uint, Address>>,
pub posdao_transition: Option<Uint>,
pub rewrite_bytecode_transitions: Option<BTreeMap<Uint, BTreeMap<Address, Bytes>>>,
}
Expand description
Authority params deserialization.
Fields
step_duration: StepDuration
Block duration, in seconds.
validators: ValidatorSet
Valid authorities
start_step: Option<Uint>
Starting step. Determined automatically if not specified. To be used for testing only.
validate_score_transition: Option<Uint>
Block at which score validation should start.
validate_step_transition: Option<Uint>
Block from which monotonic steps start.
immediate_transitions: Option<bool>
Whether transitions should be immediate.
block_reward: Option<BlockReward>
Reward per block in wei.
block_reward_contract_transition: Option<Uint>
Block at which the block reward contract should start being used. This option allows one to
add a single block reward contract transition and is compatible with the multiple address
option block_reward_contract_transitions
below.
block_reward_contract_address: Option<Address>
Block reward contract address which overrides the block_reward
setting. This option allows
one to add a single block reward contract address and is compatible with the multiple
address option block_reward_contract_transitions
below.
block_reward_contract_transitions: Option<BTreeMap<Uint, Address>>
Block reward contract addresses with their associated starting block numbers.
Setting the block reward contract overrides block_reward
. If the single block reward
contract address is also present then it is added into the map at the block number stored in
block_reward_contract_transition
or 0 if that block number is not provided. Therefore both
a single block reward contract transition and a map of reward contract transitions can be
used simulataneously in the same configuration. In such a case the code requires that the
block number of the single transition is strictly less than any of the block numbers in the
map.
block_reward_contract_code: Option<Bytes>
Block reward code. This overrides the block reward contract address.
maximum_uncle_count_transition: Option<Uint>
Block at which maximum uncle count should be considered.
maximum_uncle_count: Option<Uint>
Maximum number of accepted uncles.
empty_steps_transition: Option<Uint>
Block at which empty step messages should start.
maximum_empty_steps: Option<Uint>
Maximum number of accepted empty steps.
strict_empty_steps_transition: Option<Uint>
Strict validation of empty steps transition block.
two_thirds_majority_transition: Option<Uint>
First block for which a 2/3 quorum (instead of 1/2) is required.
randomness_contract_address: Option<BTreeMap<Uint, Address>>
The random number contract’s address, or a map of contract transitions.
block_gas_limit_contract_transitions: Option<BTreeMap<Uint, Address>>
The addresses of contracts that determine the block gas limit starting from the block number associated with each of those contracts.
posdao_transition: Option<Uint>
The block number at which the consensus engine switches from AuRa to AuRa with POSDAO modifications.
rewrite_bytecode_transitions: Option<BTreeMap<Uint, BTreeMap<Address, Bytes>>>
The block numbers at which the bytecodes should be rewritten for the specified contracts (can be more than one per block)
Trait Implementations
sourceimpl Debug for AuthorityRoundParams
impl Debug for AuthorityRoundParams
sourceimpl<'de> Deserialize<'de> for AuthorityRoundParams
impl<'de> Deserialize<'de> for AuthorityRoundParams
sourcefn 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
sourceimpl PartialEq<AuthorityRoundParams> for AuthorityRoundParams
impl PartialEq<AuthorityRoundParams> for AuthorityRoundParams
sourcefn eq(&self, other: &AuthorityRoundParams) -> bool
fn eq(&self, other: &AuthorityRoundParams) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &AuthorityRoundParams) -> bool
fn ne(&self, other: &AuthorityRoundParams) -> bool
This method tests for !=
.
impl StructuralPartialEq for AuthorityRoundParams
Auto Trait Implementations
impl RefUnwindSafe for AuthorityRoundParams
impl Send for AuthorityRoundParams
impl Sync for AuthorityRoundParams
impl Unpin for AuthorityRoundParams
impl UnwindSafe for AuthorityRoundParams
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more