Struct chain_impl_mockchain::vote::CommitteeId
source · pub struct CommitteeId([u8; 32]);
Expand description
committee identifier
this value is used to identify a committee member on chain as well as to use as input for the vote casting payload.
Tuple Fields§
§0: [u8; 32]
Implementations§
source§impl CommitteeId
impl CommitteeId
pub const COMMITTEE_ID_SIZE: usize = 32usize
sourcepub fn from_hex(s: &str) -> Result<Self, FromHexError>
pub fn from_hex(s: &str) -> Result<Self, FromHexError>
read the identifier from the hexadecimal string
pub fn public_key(&self) -> PublicKey<Ed25519>
Trait Implementations§
source§impl Arbitrary for CommitteeId
impl Arbitrary for CommitteeId
source§impl AsRef<[u8]> for CommitteeId
impl AsRef<[u8]> for CommitteeId
source§impl Clone for CommitteeId
impl Clone for CommitteeId
source§fn clone(&self) -> CommitteeId
fn clone(&self) -> CommitteeId
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 ConfigParamVariant for CommitteeId
impl ConfigParamVariant for CommitteeId
source§impl Debug for CommitteeId
impl Debug for CommitteeId
source§impl DeserializeFromSlice for CommitteeId
impl DeserializeFromSlice for CommitteeId
fn deserialize_from_slice(codec: &mut Codec<&[u8]>) -> Result<Self, ReadError>
fn deserialize_validate_from_slice( codec: &mut Codec<&[u8]> ) -> Result<(), ReadError>
source§impl Display for CommitteeId
impl Display for CommitteeId
source§impl From<CommitteeId> for [u8; 32]
impl From<CommitteeId> for [u8; 32]
source§fn from(id: CommitteeId) -> Self
fn from(id: CommitteeId) -> Self
Converts to this type from the input type.
source§impl From<CommitteeId> for PublicKey<Ed25519>
impl From<CommitteeId> for PublicKey<Ed25519>
source§fn from(id: CommitteeId) -> Self
fn from(id: CommitteeId) -> Self
Converts to this type from the input type.
source§impl From<PublicKey<Ed25519>> for CommitteeId
impl From<PublicKey<Ed25519>> for CommitteeId
source§impl FromStr for CommitteeId
impl FromStr for CommitteeId
source§impl Hash for CommitteeId
impl Hash for CommitteeId
source§impl PartialEq<CommitteeId> for CommitteeId
impl PartialEq<CommitteeId> for CommitteeId
source§fn eq(&self, other: &CommitteeId) -> bool
fn eq(&self, other: &CommitteeId) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl Serialize for CommitteeId
impl Serialize for CommitteeId
source§impl<'a> TryFrom<&'a [u8]> for CommitteeId
impl<'a> TryFrom<&'a [u8]> for CommitteeId
impl Copy for CommitteeId
impl Eq for CommitteeId
impl StructuralEq for CommitteeId
impl StructuralPartialEq for CommitteeId
Auto Trait Implementations§
impl RefUnwindSafe for CommitteeId
impl Send for CommitteeId
impl Sync for CommitteeId
impl Unpin for CommitteeId
impl UnwindSafe for CommitteeId
Blanket Implementations§
§impl<T> Base32Len for Twhere
T: AsRef<[u8]>,
impl<T> Base32Len for Twhere T: AsRef<[u8]>,
§fn base32_len(&self) -> usize
fn base32_len(&self) -> usize
Calculate the base32 serialized length
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
§impl<T> Pointable for T
impl<T> Pointable for T
source§impl<T> ToHex for Twhere
T: AsRef<[u8]>,
impl<T> ToHex for Twhere T: AsRef<[u8]>,
source§fn encode_hex<U>(&self) -> Uwhere
U: FromIterator<char>,
fn encode_hex<U>(&self) -> Uwhere U: FromIterator<char>,
Encode the hex strict representing
self
into the result. Lower case
letters are used (e.g. f9b4ca
)source§fn encode_hex_upper<U>(&self) -> Uwhere
U: FromIterator<char>,
fn encode_hex_upper<U>(&self) -> Uwhere U: FromIterator<char>,
Encode the hex strict representing
self
into the result. Upper case
letters are used (e.g. F9B4CA
)