pub struct Stats { /* private fields */ }Expand description
Additively extensible statistics over current knowledge-node text.
Fields are private so new metrics can be added without breaking Rust callers. Serialized consumers must ignore unknown fields.
Implementations§
Source§impl Stats
impl Stats
Sourcepub fn node_count(&self) -> u64
pub fn node_count(&self) -> u64
Returns the number of current knowledge nodes.
Sourcepub fn full_node_characters(&self) -> u64
pub fn full_node_characters(&self) -> u64
Returns Unicode-character count across all three node text fields.
Sourcepub fn full_node_words(&self) -> u64
pub fn full_node_words(&self) -> u64
Returns whitespace-delimited word count across all node text fields.
Sourcepub fn estimated_full_node_tokens(&self) -> u64
pub fn estimated_full_node_tokens(&self) -> u64
Returns the full-text character count divided by four, rounded up.
Sourcepub fn long_description_characters(&self) -> u64
pub fn long_description_characters(&self) -> u64
Returns Unicode-character count for long descriptions only.
Sourcepub fn long_description_words(&self) -> u64
pub fn long_description_words(&self) -> u64
Returns whitespace-delimited word count for long descriptions only.
Sourcepub fn estimated_long_description_tokens(&self) -> u64
pub fn estimated_long_description_tokens(&self) -> u64
Returns the long-description character count divided by four, rounded up.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Stats
impl RefUnwindSafe for Stats
impl Send for Stats
impl Sync for Stats
impl Unpin for Stats
impl UnsafeUnpin for Stats
impl UnwindSafe for Stats
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