Struct twitch_types::color::HexColor
source · pub struct HexColor(/* private fields */);
Available on crate feature
color
only.Expand description
A color in hex
Implementations§
source§impl HexColor
impl HexColor
sourcepub fn from_static(raw: &'static str) -> Self
pub fn from_static(raw: &'static str) -> Self
Constructs a newHexColorfrom a static reference
sourcepub fn into_boxed_ref(self) -> Box<HexColorRef>
pub fn into_boxed_ref(self) -> Box<HexColorRef>
Converts this HexColor
into a Box<HexColorRef>
This will drop any excess capacity.
Methods from Deref<Target = HexColorRef>§
sourcepub fn as_cow(&self) -> Cow<'_, HexColorRef>
pub fn as_cow(&self) -> Cow<'_, HexColorRef>
Get a
Cow<'_, HexColorRef>
Trait Implementations§
source§impl<'a> Arbitrary<'a> for HexColor
Available on crate feature arbitrary
only.
impl<'a> Arbitrary<'a> for HexColor
Available on crate feature
arbitrary
only.source§fn arbitrary(u: &mut Unstructured<'a>) -> Result<Self>
fn arbitrary(u: &mut Unstructured<'a>) -> Result<Self>
Generate an arbitrary value of
Self
from the given unstructured data. Read moresource§fn arbitrary_take_rest(u: Unstructured<'a>) -> Result<Self, Error>
fn arbitrary_take_rest(u: Unstructured<'a>) -> Result<Self, Error>
Generate an arbitrary value of
Self
from the entirety of the given
unstructured data. Read moresource§impl AsRef<HexColorRef> for HexColor
impl AsRef<HexColorRef> for HexColor
source§fn as_ref(&self) -> &HexColorRef
fn as_ref(&self) -> &HexColorRef
Converts this type into a shared reference of the (usually inferred) input type.
source§impl Borrow<HexColorRef> for HexColor
impl Borrow<HexColorRef> for HexColor
source§fn borrow(&self) -> &HexColorRef
fn borrow(&self) -> &HexColorRef
Immutably borrows from an owned value. Read more
source§impl<'de> Deserialize<'de> for HexColor
Available on crate feature serde
only.
impl<'de> Deserialize<'de> for HexColor
Available on crate feature
serde
only.source§fn 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
source§impl<'a> From<&'a HexColor> for &'a HexColorRef
impl<'a> From<&'a HexColor> for &'a HexColorRef
source§impl From<&HexColorRef> for HexColor
impl From<&HexColorRef> for HexColor
source§fn from(s: &HexColorRef) -> Self
fn from(s: &HexColorRef) -> Self
Converts to this type from the input type.
source§impl From<Box<HexColorRef>> for HexColor
impl From<Box<HexColorRef>> for HexColor
source§fn from(r: Box<HexColorRef>) -> Self
fn from(r: Box<HexColorRef>) -> Self
Converts to this type from the input type.
source§impl<'a> From<Cow<'a, HexColorRef>> for HexColor
impl<'a> From<Cow<'a, HexColorRef>> for HexColor
source§fn from(r: Cow<'a, HexColorRef>) -> Self
fn from(r: Cow<'a, HexColorRef>) -> Self
Converts to this type from the input type.
source§impl<'a> From<HexColor> for NamedUserColor<'a>
impl<'a> From<HexColor> for NamedUserColor<'a>
source§impl<'a> IntoCow<'a, HexColorRef> for &'a HexColor
impl<'a> IntoCow<'a, HexColorRef> for &'a HexColor
source§fn into_cow(self) -> Cow<'a, HexColorRef>
fn into_cow(self) -> Cow<'a, HexColorRef>
Make the cow with proper ownership, muu
source§impl<'a> IntoCow<'a, HexColorRef> for HexColor
impl<'a> IntoCow<'a, HexColorRef> for HexColor
source§fn into_cow(self) -> Cow<'a, HexColorRef>
fn into_cow(self) -> Cow<'a, HexColorRef>
Make the cow with proper ownership, muu
source§impl Ord for HexColor
impl Ord for HexColor
source§impl PartialEq<&HexColor> for HexColor
impl PartialEq<&HexColor> for HexColor
source§impl PartialEq<&HexColorRef> for HexColor
impl PartialEq<&HexColorRef> for HexColor
source§fn eq(&self, other: &&HexColorRef) -> bool
fn eq(&self, other: &&HexColorRef) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl PartialEq<HexColor> for &HexColorRef
impl PartialEq<HexColor> for &HexColorRef
source§impl PartialEq<HexColor> for HexColorRef
impl PartialEq<HexColor> for HexColorRef
source§impl PartialEq<HexColorRef> for HexColor
impl PartialEq<HexColorRef> for HexColor
source§fn eq(&self, other: &HexColorRef) -> bool
fn eq(&self, other: &HexColorRef) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl PartialEq for HexColor
impl PartialEq for HexColor
source§impl PartialOrd for HexColor
impl PartialOrd for HexColor
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<'zf> ZeroFrom<'zf, HexColor> for &'zf HexColorRef
Available on crate feature zerofrom
only.
impl<'zf> ZeroFrom<'zf, HexColor> for &'zf HexColorRef
Available on crate feature
zerofrom
only.impl Eq for HexColor
impl StructuralPartialEq for HexColor
Auto Trait Implementations§
impl Freeze for HexColor
impl RefUnwindSafe for HexColor
impl Send for HexColor
impl Sync for HexColor
impl Unpin for HexColor
impl UnwindSafe for HexColor
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