pub struct DRepVotingThresholds { /* private fields */ }
Implementations§
Source§impl DRepVotingThresholds
impl DRepVotingThresholds
pub fn from_bytes( bytes: Vec<u8>, ) -> Result<DRepVotingThresholds, DeserializeError>
Source§impl DRepVotingThresholds
impl DRepVotingThresholds
pub fn from_hex(hex_str: &str) -> Result<DRepVotingThresholds, DeserializeError>
Source§impl DRepVotingThresholds
impl DRepVotingThresholds
pub fn new( motion_no_confidence: &UnitInterval, committee_normal: &UnitInterval, committee_no_confidence: &UnitInterval, update_constitution: &UnitInterval, hard_fork_initiation: &UnitInterval, pp_network_group: &UnitInterval, pp_economic_group: &UnitInterval, pp_technical_group: &UnitInterval, pp_governance_group: &UnitInterval, treasury_withdrawal: &UnitInterval, ) -> Self
pub fn set_motion_no_confidence(&mut self, motion_no_confidence: &UnitInterval)
pub fn set_committee_normal(&mut self, committee_normal: &UnitInterval)
pub fn set_committee_no_confidence( &mut self, committee_no_confidence: &UnitInterval, )
pub fn set_update_constitution(&mut self, update_constitution: &UnitInterval)
pub fn set_hard_fork_initiation(&mut self, hard_fork_initiation: &UnitInterval)
pub fn set_pp_network_group(&mut self, pp_network_group: &UnitInterval)
pub fn set_pp_economic_group(&mut self, pp_economic_group: &UnitInterval)
pub fn set_pp_technical_group(&mut self, pp_technical_group: &UnitInterval)
pub fn set_pp_governance_group(&mut self, pp_governance_group: &UnitInterval)
pub fn set_treasury_withdrawal(&mut self, treasury_withdrawal: &UnitInterval)
pub fn motion_no_confidence(&self) -> UnitInterval
pub fn committee_normal(&self) -> UnitInterval
pub fn committee_no_confidence(&self) -> UnitInterval
pub fn update_constitution(&self) -> UnitInterval
pub fn hard_fork_initiation(&self) -> UnitInterval
pub fn pp_network_group(&self) -> UnitInterval
pub fn pp_economic_group(&self) -> UnitInterval
pub fn pp_technical_group(&self) -> UnitInterval
pub fn pp_governance_group(&self) -> UnitInterval
pub fn treasury_withdrawal(&self) -> UnitInterval
Trait Implementations§
Source§impl Clone for DRepVotingThresholds
impl Clone for DRepVotingThresholds
Source§fn clone(&self) -> DRepVotingThresholds
fn clone(&self) -> DRepVotingThresholds
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 DRepVotingThresholds
impl Debug for DRepVotingThresholds
Source§impl Default for DRepVotingThresholds
impl Default for DRepVotingThresholds
Source§fn default() -> DRepVotingThresholds
fn default() -> DRepVotingThresholds
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for DRepVotingThresholds
impl<'de> Deserialize<'de> for DRepVotingThresholds
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
Source§impl Hash for DRepVotingThresholds
impl Hash for DRepVotingThresholds
Source§impl JsonSchema for DRepVotingThresholds
impl JsonSchema for DRepVotingThresholds
Source§fn schema_name() -> String
fn schema_name() -> String
The name of the generated JSON Schema. Read more
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn is_referenceable() -> bool
fn is_referenceable() -> bool
Whether JSON Schemas generated for this type should be re-used where possible using the
$ref
keyword. Read moreSource§impl Ord for DRepVotingThresholds
impl Ord for DRepVotingThresholds
Source§fn cmp(&self, other: &DRepVotingThresholds) -> Ordering
fn cmp(&self, other: &DRepVotingThresholds) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for DRepVotingThresholds
impl PartialEq for DRepVotingThresholds
Source§impl PartialOrd for DRepVotingThresholds
impl PartialOrd for DRepVotingThresholds
Source§impl Serialize for DRepVotingThresholds
impl Serialize for DRepVotingThresholds
Source§impl Serialize for DRepVotingThresholds
impl Serialize for DRepVotingThresholds
fn serialize<'se, W: Write>( &self, serializer: &'se mut Serializer<W>, ) -> Result<&'se mut Serializer<W>>
impl Eq for DRepVotingThresholds
impl StructuralPartialEq for DRepVotingThresholds
Auto Trait Implementations§
impl Freeze for DRepVotingThresholds
impl RefUnwindSafe for DRepVotingThresholds
impl Send for DRepVotingThresholds
impl Sync for DRepVotingThresholds
impl Unpin for DRepVotingThresholds
impl UnwindSafe for DRepVotingThresholds
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more