pub struct ContentMetrics {
pub words: usize,
pub reading_time_min: usize,
pub flesch_reading_ease: f64,
pub reading_ease_label: String,
}Expand description
Word count + reading time + readability for a chunk of content.
Fields§
§words: usize§reading_time_min: usizeMinutes, ceil(words / 200). Zero when there are no words.
flesch_reading_ease: f64Flesch Reading Ease (higher = easier; ~0–100 typical). Zero when empty.
reading_ease_label: StringCoarse band for the score: Easy / Standard / Difficult,
or — when empty.
Trait Implementations§
Source§impl Clone for ContentMetrics
impl Clone for ContentMetrics
Source§impl Debug for ContentMetrics
impl Debug for ContentMetrics
Source§impl PartialEq for ContentMetrics
impl PartialEq for ContentMetrics
Source§impl Serialize for ContentMetrics
impl Serialize for ContentMetrics
impl StructuralPartialEq for ContentMetrics
Auto Trait Implementations§
impl Forget for ContentMetrics
impl Freeze for ContentMetrics
impl RefUnwindSafe for ContentMetrics
impl Send for ContentMetrics
impl Sync for ContentMetrics
impl Unpin for ContentMetrics
impl UnsafeUnpin for ContentMetrics
impl UnwindSafe for ContentMetrics
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
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> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
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 moreCreates a shared type from an unshared type.