Struct style::context::TraversalStatistics
source · pub struct TraversalStatistics {
pub aggregated: PerThreadTraversalStatistics,
pub selectors: u32,
pub revalidation_selectors: u32,
pub dependency_selectors: u32,
pub declarations: u32,
pub stylist_rebuilds: u32,
pub traversal_time_ms: f64,
pub is_parallel: bool,
pub is_large: bool,
}
Expand description
Statistics gathered during the traversal plus some information from other sources including stylist.
Fields§
§aggregated: PerThreadTraversalStatistics
Aggregated statistics gathered during the traversal.
selectors: u32
The number of selectors in the stylist.
revalidation_selectors: u32
The number of revalidation selectors.
dependency_selectors: u32
The number of state/attr dependencies in the dependency set.
declarations: u32
The number of declarations in the stylist.
stylist_rebuilds: u32
The number of times the stylist was rebuilt.
traversal_time_ms: f64
Time spent in the traversal, in milliseconds.
is_parallel: bool
Whether this was a parallel traversal.
is_large: bool
Whether this is a “large” traversal.
Implementations§
source§impl TraversalStatistics
impl TraversalStatistics
sourcepub fn new<E, D>(
aggregated: PerThreadTraversalStatistics,
traversal: &D,
parallel: bool,
start: f64
) -> TraversalStatisticswhere
E: TElement,
D: DomTraversal<E>,
pub fn new<E, D>( aggregated: PerThreadTraversalStatistics, traversal: &D, parallel: bool, start: f64 ) -> TraversalStatisticswhere E: TElement, D: DomTraversal<E>,
Generate complete traversal statistics.
The traversal time is computed given the start time in seconds.
Trait Implementations§
source§impl Default for TraversalStatistics
impl Default for TraversalStatistics
source§fn default() -> TraversalStatistics
fn default() -> TraversalStatistics
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl RefUnwindSafe for TraversalStatistics
impl Send for TraversalStatistics
impl Sync for TraversalStatistics
impl Unpin for TraversalStatistics
impl UnwindSafe for TraversalStatistics
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
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>where
F: FnOnce(&Self) -> bool,
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>where F: FnOnce(&Self) -> bool,
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§impl<T> MaybeBoxed<Box<T, Global>> for T
impl<T> MaybeBoxed<Box<T, Global>> for T
source§fn maybe_boxed(self) -> Box<T, Global>
fn maybe_boxed(self) -> Box<T, Global>
Convert
source§impl<T> MaybeBoxed<T> for T
impl<T> MaybeBoxed<T> for T
source§fn maybe_boxed(self) -> T
fn maybe_boxed(self) -> T
Convert