pub struct BondParticipant(/* private fields */);Expand description
A validated bond participant reference.
Implementations§
Source§impl BondParticipant
impl BondParticipant
Sourcepub fn new(label: &str) -> Result<Self, BondValidationError>
pub fn new(label: &str) -> Result<Self, BondValidationError>
Creates a bond participant label.
§Errors
Returns BondValidationError::EmptyParticipantLabel when label is empty after trimming.
Sourcepub fn into_string(self) -> String
pub fn into_string(self) -> String
Consumes the participant and returns the owned label.
Trait Implementations§
Source§impl AsRef<str> for BondParticipant
impl AsRef<str> for BondParticipant
Source§impl Clone for BondParticipant
impl Clone for BondParticipant
Source§fn clone(&self) -> BondParticipant
fn clone(&self) -> BondParticipant
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 moreSource§impl Debug for BondParticipant
impl Debug for BondParticipant
Source§impl Display for BondParticipant
impl Display for BondParticipant
Source§impl Hash for BondParticipant
impl Hash for BondParticipant
Source§impl Ord for BondParticipant
impl Ord for BondParticipant
Source§fn cmp(&self, other: &BondParticipant) -> Ordering
fn cmp(&self, other: &BondParticipant) -> 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 BondParticipant
impl PartialEq for BondParticipant
Source§fn eq(&self, other: &BondParticipant) -> bool
fn eq(&self, other: &BondParticipant) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl PartialOrd for BondParticipant
impl PartialOrd for BondParticipant
Source§impl TryFrom<&str> for BondParticipant
impl TryFrom<&str> for BondParticipant
impl Eq for BondParticipant
impl StructuralPartialEq for BondParticipant
Auto Trait Implementations§
impl Freeze for BondParticipant
impl RefUnwindSafe for BondParticipant
impl Send for BondParticipant
impl Sync for BondParticipant
impl Unpin for BondParticipant
impl UnsafeUnpin for BondParticipant
impl UnwindSafe for BondParticipant
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