Struct jormungandr_lib::interfaces::committee::CommitteeId
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§
§impl CommitteeId
impl CommitteeId
pub const COMMITTEE_ID_SIZE: usize = 32usize
pub fn from_hex(s: &str) -> Result<CommitteeId, FromHexError>
pub fn from_hex(s: &str) -> Result<CommitteeId, FromHexError>
read the identifier from the hexadecimal string
pub fn public_key(&self) -> PublicKey<Ed25519>
Trait Implementations§
§impl Arbitrary for CommitteeId
impl Arbitrary for CommitteeId
§impl AsRef<[u8]> for CommitteeId
impl AsRef<[u8]> for CommitteeId
§impl Clone for CommitteeId
impl Clone for CommitteeId
§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 more§impl Debug for CommitteeId
impl Debug for CommitteeId
§impl DeserializeFromSlice for CommitteeId
impl DeserializeFromSlice for CommitteeId
fn deserialize_from_slice( codec: &mut Codec<&[u8]> ) -> Result<CommitteeId, ReadError>
fn deserialize_validate_from_slice( codec: &mut Codec<&[u8]> ) -> Result<(), ReadError>
§impl Display for CommitteeId
impl Display for CommitteeId
§impl From<[u8; 32]> for CommitteeId
impl From<[u8; 32]> for CommitteeId
§fn from(id: [u8; 32]) -> CommitteeId
fn from(id: [u8; 32]) -> CommitteeId
Converts to this type from the input type.
source§impl From<CommitteeId> for CommitteeIdDef
impl From<CommitteeId> for CommitteeIdDef
source§fn from(committee_id: CommitteeId) -> Self
fn from(committee_id: CommitteeId) -> Self
Converts to this type from the input type.
source§impl From<CommitteeIdDef> for CommitteeId
impl From<CommitteeIdDef> for CommitteeId
source§fn from(committee_id_def: CommitteeIdDef) -> Self
fn from(committee_id_def: CommitteeIdDef) -> Self
Converts to this type from the input type.
§impl From<PublicKey<Ed25519>> for CommitteeId
impl From<PublicKey<Ed25519>> for CommitteeId
§fn from(key: PublicKey<Ed25519>) -> CommitteeId
fn from(key: PublicKey<Ed25519>) -> CommitteeId
Converts to this type from the input type.
§impl FromStr for CommitteeId
impl FromStr for CommitteeId
§type Err = FromHexError
type Err = FromHexError
The associated error which can be returned from parsing.
§fn from_str(s: &str) -> Result<CommitteeId, <CommitteeId as FromStr>::Err>
fn from_str(s: &str) -> Result<CommitteeId, <CommitteeId as FromStr>::Err>
Parses a string
s
to return a value of this type. Read more§impl Hash for CommitteeId
impl Hash for CommitteeId
§impl PartialEq<CommitteeId> for CommitteeId
impl PartialEq<CommitteeId> for CommitteeId
§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 ==
.§impl Serialize for CommitteeId
impl Serialize for CommitteeId
§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
)