pub struct RuntimeStakingParameters {
pub thresholds: BTreeMap<ThresholdKind, Quantity>,
pub slashing: BTreeMap<SlashReason, Slash>,
pub reward_equivocation: u8,
pub reward_bad_results: u8,
pub min_in_message_fee: Quantity,
}
Expand description
Stake-related parameters for a runtime.
Fields§
§thresholds: BTreeMap<ThresholdKind, Quantity>
Minimum stake thresholds for a runtime. These per-runtime thresholds are in addition to the global thresholds. May be left unspecified.
In case a node is registered for multiple runtimes, it will need to satisfy the maximum threshold of all the runtimes.
slashing: BTreeMap<SlashReason, Slash>
Per-runtime misbehavior slashing parameters.
reward_equivocation: u8
The percentage of the reward obtained when slashing for equivocation that is transferred to the runtime’s account.
reward_bad_results: u8
The percentage of the reward obtained when slashing for incorrect results that is transferred to the runtime’s account.
min_in_message_fee: Quantity
Specifies the minimum fee that the incoming message must include for the message to be queued.
Trait Implementations§
source§impl Clone for RuntimeStakingParameters
impl Clone for RuntimeStakingParameters
source§fn clone(&self) -> RuntimeStakingParameters
fn clone(&self) -> RuntimeStakingParameters
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for RuntimeStakingParameters
impl Debug for RuntimeStakingParameters
source§impl Decode for RuntimeStakingParameters
impl Decode for RuntimeStakingParameters
source§fn try_default() -> Result<Self, DecodeError>
fn try_default() -> Result<Self, DecodeError>
Try to decode from a missing/null/undefined value.
source§fn try_from_cbor_value(value: Value) -> Result<Self, DecodeError>
fn try_from_cbor_value(value: Value) -> Result<Self, DecodeError>
Try to decode from a given CBOR value.
§fn try_from_cbor_value_default(value: Value) -> Result<Self, DecodeError>where
Self: Sized,
fn try_from_cbor_value_default(value: Value) -> Result<Self, DecodeError>where
Self: Sized,
Try to decode from a given CBOR value, calling
try_default
in case the value is null or
undefined.source§impl Default for RuntimeStakingParameters
impl Default for RuntimeStakingParameters
source§fn default() -> RuntimeStakingParameters
fn default() -> RuntimeStakingParameters
Returns the “default value” for a type. Read more
source§impl Encode for RuntimeStakingParameters
impl Encode for RuntimeStakingParameters
source§impl EncodeAsMap for RuntimeStakingParameters
impl EncodeAsMap for RuntimeStakingParameters
§fn into_cbor_value_map(self) -> Valuewhere
Self: Sized,
fn into_cbor_value_map(self) -> Valuewhere
Self: Sized,
Encode the type into a CBOR Map.
§fn into_cbor_map(self) -> Vec<(Value, Value)>where
Self: Sized,
fn into_cbor_map(self) -> Vec<(Value, Value)>where
Self: Sized,
Encode the type into a CBOR Map, returning the map items.
source§impl Hash for RuntimeStakingParameters
impl Hash for RuntimeStakingParameters
source§impl PartialEq for RuntimeStakingParameters
impl PartialEq for RuntimeStakingParameters
source§fn eq(&self, other: &RuntimeStakingParameters) -> bool
fn eq(&self, other: &RuntimeStakingParameters) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Eq for RuntimeStakingParameters
impl StructuralPartialEq for RuntimeStakingParameters
Auto Trait Implementations§
impl Freeze for RuntimeStakingParameters
impl RefUnwindSafe for RuntimeStakingParameters
impl Send for RuntimeStakingParameters
impl Sync for RuntimeStakingParameters
impl Unpin for RuntimeStakingParameters
impl UnwindSafe for RuntimeStakingParameters
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.