Struct BondParticipant
pub struct BondParticipant(/* private fields */);Expand description
A validated bond participant reference.
Implementations§
§impl BondParticipant
impl BondParticipant
pub fn new(label: &str) -> Result<BondParticipant, BondValidationError>
pub fn new(label: &str) -> Result<BondParticipant, BondValidationError>
Creates a bond participant label.
§Errors
Returns BondValidationError::EmptyParticipantLabel when label is empty after trimming.
pub fn into_string(self) -> String
pub fn into_string(self) -> String
Consumes the participant and returns the owned label.
Trait Implementations§
§impl AsRef<str> for BondParticipant
impl AsRef<str> for BondParticipant
§impl Clone for BondParticipant
impl Clone for BondParticipant
§fn clone(&self) -> BondParticipant
fn clone(&self) -> BondParticipant
Returns a duplicate 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 BondParticipant
impl Debug for BondParticipant
§impl Display for BondParticipant
impl Display for BondParticipant
§impl Hash for BondParticipant
impl Hash for BondParticipant
§impl Ord for BondParticipant
impl Ord for BondParticipant
§impl PartialEq for BondParticipant
impl PartialEq for BondParticipant
§impl PartialOrd for BondParticipant
impl PartialOrd for BondParticipant
§impl TryFrom<&str> for BondParticipant
impl TryFrom<&str> for BondParticipant
§type Error = BondValidationError
type Error = BondValidationError
The type returned in the event of a conversion error.
§fn try_from(
value: &str,
) -> Result<BondParticipant, <BondParticipant as TryFrom<&str>>::Error>
fn try_from( value: &str, ) -> Result<BondParticipant, <BondParticipant as TryFrom<&str>>::Error>
Performs the conversion.
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