pub struct ObjectStats {
pub dict_count: usize,
pub array_count: usize,
pub stream_count: usize,
pub reference_count: usize,
pub primitive_count: usize,
pub total_visited: usize,
}Expand description
A built-in visitor that collects object type statistics.
Fields§
§dict_count: usizeNumber of dictionaries visited.
array_count: usizeNumber of arrays visited.
stream_count: usizeNumber of streams visited.
reference_count: usizeNumber of references visited.
primitive_count: usizeNumber of primitive values visited.
total_visited: usizeTotal number of visitor callbacks.
Trait Implementations§
Source§impl Clone for ObjectStats
impl Clone for ObjectStats
Source§fn clone(&self) -> ObjectStats
fn clone(&self) -> ObjectStats
Returns a duplicate 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 Debug for ObjectStats
impl Debug for ObjectStats
Source§impl Default for ObjectStats
impl Default for ObjectStats
Source§fn default() -> ObjectStats
fn default() -> ObjectStats
Returns the “default value” for a type. Read more
Source§impl ObjectVisitor for ObjectStats
impl ObjectVisitor for ObjectStats
Source§fn visit_dict(&mut self, _id: Option<ObjectId>, _dict: &HashMap<Name, Object>)
fn visit_dict(&mut self, _id: Option<ObjectId>, _dict: &HashMap<Name, Object>)
Called for each dictionary encountered.
Source§fn visit_array(&mut self, _id: Option<ObjectId>, _arr: &[Object])
fn visit_array(&mut self, _id: Option<ObjectId>, _arr: &[Object])
Called for each array encountered.
Source§fn visit_stream(&mut self, _id: Option<ObjectId>)
fn visit_stream(&mut self, _id: Option<ObjectId>)
Called for each stream encountered.
Source§fn visit_reference(&mut self, _target: ObjectId)
fn visit_reference(&mut self, _target: ObjectId)
Called for each reference encountered.
Auto Trait Implementations§
impl Freeze for ObjectStats
impl RefUnwindSafe for ObjectStats
impl Send for ObjectStats
impl Sync for ObjectStats
impl Unpin for ObjectStats
impl UnsafeUnpin for ObjectStats
impl UnwindSafe for ObjectStats
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