Struct twitch_types::Nickname
source · [−]#[repr(transparent)]pub struct Nickname(_);
Expand description
A nickname, not capitalized.
Implementations
sourceimpl Nickname
impl Nickname
sourcepub fn from_static(raw: &'static str) -> Self
pub fn from_static(raw: &'static str) -> Self
Constructs a new Nickname from a static reference
sourcepub fn into_boxed_ref(self) -> Box<NicknameRef>
pub fn into_boxed_ref(self) -> Box<NicknameRef>
Converts this Nickname
into a Box<NicknameRef>
This will drop any excess capacity.
Methods from Deref<Target = NicknameRef>
sourcepub fn as_cow<'a>(&'a self) -> Cow<'a, NicknameRef>
pub fn as_cow<'a>(&'a self) -> Cow<'a, NicknameRef>
Get a
Cow<'_, NicknameRef>
Trait Implementations
sourceimpl AsRef<NicknameRef> for Nickname
impl AsRef<NicknameRef> for Nickname
sourcefn as_ref(&self) -> &NicknameRef
fn as_ref(&self) -> &NicknameRef
Converts this type into a shared reference of the (usually inferred) input type.
sourceimpl Borrow<NicknameRef> for Nickname
impl Borrow<NicknameRef> for Nickname
sourcefn borrow(&self) -> &NicknameRef
fn borrow(&self) -> &NicknameRef
Immutably borrows from an owned value. Read more
sourceimpl Deref for Nickname
impl Deref for Nickname
type Target = NicknameRef
type Target = NicknameRef
The resulting type after dereferencing.
sourceimpl<'de> Deserialize<'de> for Nickname
impl<'de> Deserialize<'de> for Nickname
sourcefn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
Deserialize this value from the given Serde deserializer. Read more
sourceimpl<'a> From<&'a Nickname> for &'a NicknameRef
impl<'a> From<&'a Nickname> for &'a NicknameRef
sourceimpl<'a> From<&'a Nickname> for Cow<'a, NicknameRef>
impl<'a> From<&'a Nickname> for Cow<'a, NicknameRef>
sourceimpl From<&NicknameRef> for Nickname
impl From<&NicknameRef> for Nickname
sourcefn from(s: &NicknameRef) -> Self
fn from(s: &NicknameRef) -> Self
Converts to this type from the input type.
sourceimpl From<Box<NicknameRef, Global>> for Nickname
impl From<Box<NicknameRef, Global>> for Nickname
sourcefn from(r: Box<NicknameRef>) -> Self
fn from(r: Box<NicknameRef>) -> Self
Converts to this type from the input type.
sourceimpl<'a> From<Cow<'a, NicknameRef>> for Nickname
impl<'a> From<Cow<'a, NicknameRef>> for Nickname
sourcefn from(r: Cow<'a, NicknameRef>) -> Self
fn from(r: Cow<'a, NicknameRef>) -> Self
Converts to this type from the input type.
sourceimpl From<Nickname> for Box<NicknameRef>
impl From<Nickname> for Box<NicknameRef>
sourceimpl<'a> From<Nickname> for Cow<'a, NicknameRef>
impl<'a> From<Nickname> for Cow<'a, NicknameRef>
sourceimpl<'a> IntoCow<'a, NicknameRef> for &'a Nickname
impl<'a> IntoCow<'a, NicknameRef> for &'a Nickname
sourcefn to_cow(self) -> Cow<'a, NicknameRef>
fn to_cow(self) -> Cow<'a, NicknameRef>
Make the cow with proper ownership, muu
sourceimpl<'a> IntoCow<'a, NicknameRef> for Nickname
impl<'a> IntoCow<'a, NicknameRef> for Nickname
sourcefn to_cow(self) -> Cow<'a, NicknameRef>
fn to_cow(self) -> Cow<'a, NicknameRef>
Make the cow with proper ownership, muu
sourceimpl Ord for Nickname
impl Ord for Nickname
1.21.0 · sourcefn 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
1.21.0 · sourcefn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more
1.50.0 · sourcefn clamp(self, min: Self, max: Self) -> Selfwhere
Self: Sized + PartialOrd<Self>,
fn clamp(self, min: Self, max: Self) -> Selfwhere
Self: Sized + PartialOrd<Self>,
Restrict a value to a certain interval. Read more
sourceimpl PartialEq<&NicknameRef> for Nickname
impl PartialEq<&NicknameRef> for Nickname
sourcefn eq(&self, other: &&NicknameRef) -> bool
fn eq(&self, other: &&NicknameRef) -> bool
sourceimpl PartialEq<NicknameRef> for Nickname
impl PartialEq<NicknameRef> for Nickname
sourcefn eq(&self, other: &NicknameRef) -> bool
fn eq(&self, other: &NicknameRef) -> bool
sourceimpl PartialOrd<Nickname> for Nickname
impl PartialOrd<Nickname> for Nickname
sourcefn partial_cmp(&self, other: &Self) -> Option<Ordering>
fn partial_cmp(&self, other: &Self) -> Option<Ordering>
1.0.0 · sourcefn 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 moreimpl Eq for Nickname
impl StructuralEq for Nickname
impl StructuralPartialEq for Nickname
Auto Trait Implementations
impl RefUnwindSafe for Nickname
impl Send for Nickname
impl Sync for Nickname
impl Unpin for Nickname
impl UnwindSafe for Nickname
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more