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