Struct PlatformTriple
pub struct PlatformTriple(/* private fields */);Expand description
A plain, owned platform triple value.
Implementations§
§impl PlatformTriple
impl PlatformTriple
pub fn new(
value: impl AsRef<str>,
) -> Result<PlatformTriple, PlatformTripleError>
pub fn new( value: impl AsRef<str>, ) -> Result<PlatformTriple, PlatformTripleError>
Creates a platform triple from non-empty text.
§Errors
Returns PlatformTripleError::Empty when the trimmed input is empty.
pub fn into_string(self) -> String
pub fn into_string(self) -> String
Consumes the triple and returns the owned string.
Trait Implementations§
§impl AsRef<str> for PlatformTriple
impl AsRef<str> for PlatformTriple
§impl Clone for PlatformTriple
impl Clone for PlatformTriple
§fn clone(&self) -> PlatformTriple
fn clone(&self) -> PlatformTriple
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 PlatformTriple
impl Debug for PlatformTriple
§impl Display for PlatformTriple
impl Display for PlatformTriple
§impl From<PlatformTriple> for Platform
impl From<PlatformTriple> for Platform
§fn from(triple: PlatformTriple) -> Platform
fn from(triple: PlatformTriple) -> Platform
Converts to this type from the input type.
§impl FromStr for PlatformTriple
impl FromStr for PlatformTriple
§type Err = PlatformTripleError
type Err = PlatformTripleError
The associated error which can be returned from parsing.
§fn from_str(
value: &str,
) -> Result<PlatformTriple, <PlatformTriple as FromStr>::Err>
fn from_str( value: &str, ) -> Result<PlatformTriple, <PlatformTriple as FromStr>::Err>
Parses a string
s to return a value of this type. Read more§impl Hash for PlatformTriple
impl Hash for PlatformTriple
§impl Ord for PlatformTriple
impl Ord for PlatformTriple
§impl PartialEq for PlatformTriple
impl PartialEq for PlatformTriple
§impl PartialOrd for PlatformTriple
impl PartialOrd for PlatformTriple
impl Eq for PlatformTriple
impl StructuralPartialEq for PlatformTriple
Auto Trait Implementations§
impl Freeze for PlatformTriple
impl RefUnwindSafe for PlatformTriple
impl Send for PlatformTriple
impl Sync for PlatformTriple
impl Unpin for PlatformTriple
impl UnsafeUnpin for PlatformTriple
impl UnwindSafe for PlatformTriple
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