Struct selectors::builder::Specificity
source · pub(crate) struct Specificity {
id_selectors: u32,
class_like_selectors: u32,
element_selectors: u32,
}
Fields§
§id_selectors: u32
§class_like_selectors: u32
§element_selectors: u32
Implementations§
source§impl Specificity
impl Specificity
pub fn single_class_like() -> Self
Trait Implementations§
source§impl Add for Specificity
impl Add for Specificity
§type Output = Specificity
type Output = Specificity
The resulting type after applying the
+
operator.source§fn add(self, rhs: Specificity) -> Specificity
fn add(self, rhs: Specificity) -> Specificity
Performs the
+
operation. Read moresource§impl AddAssign for Specificity
impl AddAssign for Specificity
source§fn add_assign(&mut self, rhs: Specificity)
fn add_assign(&mut self, rhs: Specificity)
Performs the
+=
operation. Read moresource§impl Clone for Specificity
impl Clone for Specificity
source§fn clone(&self) -> Specificity
fn clone(&self) -> Specificity
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 Default for Specificity
impl Default for Specificity
source§fn default() -> Specificity
fn default() -> Specificity
Returns the “default value” for a type. Read more
source§impl From<Specificity> for u32
impl From<Specificity> for u32
source§fn from(specificity: Specificity) -> u32
fn from(specificity: Specificity) -> u32
Converts to this type from the input type.
source§impl From<u32> for Specificity
impl From<u32> for Specificity
source§fn from(value: u32) -> Specificity
fn from(value: u32) -> Specificity
Converts to this type from the input type.
source§impl Ord for Specificity
impl Ord for Specificity
source§fn cmp(&self, other: &Specificity) -> Ordering
fn cmp(&self, other: &Specificity) -> 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 PartialEq for Specificity
impl PartialEq for Specificity
source§fn eq(&self, other: &Specificity) -> bool
fn eq(&self, other: &Specificity) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd for Specificity
impl PartialOrd for Specificity
source§fn partial_cmp(&self, other: &Specificity) -> Option<Ordering>
fn partial_cmp(&self, other: &Specificity) -> 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 moreimpl Copy for Specificity
impl Eq for Specificity
impl StructuralPartialEq for Specificity
Auto Trait Implementations§
impl Freeze for Specificity
impl RefUnwindSafe for Specificity
impl Send for Specificity
impl Sync for Specificity
impl Unpin for Specificity
impl UnwindSafe for Specificity
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