pub struct CandidateId(/* private fields */);Expand description
A string of type candidate id as defined in the EML_NL specification
Called CandidateIdType in the schema.
Implementations§
Source§impl CandidateId
impl CandidateId
Sourcepub fn new(value: NonZeroU64) -> Self
pub fn new(value: NonZeroU64) -> Self
Create a new CandidateId.
Sourcepub fn from_u64(value: u64) -> Result<Self, InvalidCandidateIdError>
pub fn from_u64(value: u64) -> Result<Self, InvalidCandidateIdError>
Create a new CandidateId from a u64 value.
Sourcepub fn value(&self) -> NonZeroU64
pub fn value(&self) -> NonZeroU64
Get the value of the CandidateId.
Trait Implementations§
Source§impl Clone for CandidateId
impl Clone for CandidateId
Source§fn clone(&self) -> CandidateId
fn clone(&self) -> CandidateId
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for CandidateId
Source§impl Debug for CandidateId
impl Debug for CandidateId
Source§impl Display for CandidateId
impl Display for CandidateId
impl Eq for CandidateId
Source§impl From<CandidateId> for CandidateIdentifier
impl From<CandidateId> for CandidateIdentifier
Source§fn from(value: CandidateId) -> Self
fn from(value: CandidateId) -> Self
Converts to this type from the input type.
Source§impl From<CandidateId> for CandidateSelection
impl From<CandidateId> for CandidateSelection
Source§fn from(id: CandidateId) -> Self
fn from(id: CandidateId) -> Self
Converts to this type from the input type.
Source§impl FromStr for CandidateId
impl FromStr for CandidateId
Source§impl Hash for CandidateId
impl Hash for CandidateId
Source§impl Ord for CandidateId
impl Ord for CandidateId
Source§fn cmp(&self, other: &CandidateId) -> Ordering
fn cmp(&self, other: &CandidateId) -> Ordering
1.21.0 (const: unstable) · 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 CandidateId
impl PartialEq for CandidateId
Source§impl PartialOrd for CandidateId
impl PartialOrd for CandidateId
Source§impl StringValueData for CandidateId
impl StringValueData for CandidateId
Source§type Error = InvalidCandidateIdError
type Error = InvalidCandidateIdError
The error type returned when parsing the value from a string fails.
Source§fn parse_from_str(s: &str) -> Result<Self, Self::Error>where
Self: Sized,
fn parse_from_str(s: &str) -> Result<Self, Self::Error>where
Self: Sized,
Parse the value from a string.
Source§fn to_raw_value(&self) -> Box<str>
fn to_raw_value(&self) -> Box<str>
Convert the value to its raw string representation.
impl StructuralPartialEq for CandidateId
Auto Trait Implementations§
impl Freeze for CandidateId
impl RefUnwindSafe for CandidateId
impl Send for CandidateId
impl Sync for CandidateId
impl Unpin for CandidateId
impl UnsafeUnpin for CandidateId
impl UnwindSafe for CandidateId
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