Struct cargo::util_schemas::manifest::PackageName
source · pub struct PackageName<T: AsRef<str> = String>(/* private fields */);
Expand description
Verified string newtype
Implementations§
source§impl<T: AsRef<str>> PackageName<T>
impl<T: AsRef<str>> PackageName<T>
pub fn into_inner(self) -> T
source§impl<T: AsRef<str>> PackageName<T>
impl<T: AsRef<str>> PackageName<T>
Trait Implementations§
source§impl<T: Clone + AsRef<str>> Clone for PackageName<T>
impl<T: Clone + AsRef<str>> Clone for PackageName<T>
source§fn clone(&self) -> PackageName<T>
fn clone(&self) -> PackageName<T>
Returns a copy 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 moresource§impl<'de, T: AsRef<str> + Deserialize<'de>> Deserialize<'de> for PackageName<T>
impl<'de, T: AsRef<str> + Deserialize<'de>> Deserialize<'de> for PackageName<T>
source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl<'a> FromStr for PackageName<String>
impl<'a> FromStr for PackageName<String>
source§impl<T: Ord + AsRef<str>> Ord for PackageName<T>
impl<T: Ord + AsRef<str>> Ord for PackageName<T>
source§fn cmp(&self, other: &PackageName<T>) -> Ordering
fn cmp(&self, other: &PackageName<T>) -> Ordering
1.21.0 · 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<T: PartialEq + AsRef<str>> PartialEq for PackageName<T>
impl<T: PartialEq + AsRef<str>> PartialEq for PackageName<T>
source§fn eq(&self, other: &PackageName<T>) -> bool
fn eq(&self, other: &PackageName<T>) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl<T: PartialOrd + AsRef<str>> PartialOrd for PackageName<T>
impl<T: PartialOrd + AsRef<str>> PartialOrd for PackageName<T>
source§fn partial_cmp(&self, other: &PackageName<T>) -> Option<Ordering>
fn partial_cmp(&self, other: &PackageName<T>) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresource§impl<T> Serialize for PackageName<T>
impl<T> Serialize for PackageName<T>
impl<T: Eq + AsRef<str>> Eq for PackageName<T>
impl<T: AsRef<str>> StructuralPartialEq for PackageName<T>
Auto Trait Implementations§
impl<T> RefUnwindSafe for PackageName<T>where
T: RefUnwindSafe,
impl<T> Send for PackageName<T>where
T: Send,
impl<T> Sync for PackageName<T>where
T: Sync,
impl<T> Unpin for PackageName<T>where
T: Unpin,
impl<T> UnwindSafe for PackageName<T>where
T: UnwindSafe,
Blanket Implementations§
§impl<T, A, P> Access<T> for P
impl<T, A, P> Access<T> for P
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
§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
§impl<T, A> DynAccess<T> for Awhere
A: Access<T>,
<A as Access<T>>::Guard: 'static,
impl<T, A> DynAccess<T> for Awhere
A: Access<T>,
<A as Access<T>>::Guard: 'static,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.