#[non_exhaustive]pub enum WorkUnit {
Archives,
Segments,
Nodes,
Revisions,
JournalLines,
Checkpoints,
Files,
Bytes,
}Expand description
What a step counts.
The unit tells a renderer how to word and scale a report: a count of
WorkUnit::Bytes is rendered as a size, every other unit as a plain
count of the named things.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Archives
TAR archive files.
Segments
Segments within archives.
Nodes
Content nodes.
Revisions
Journal revisions.
JournalLines
Lines of journal.log.
Checkpoints
Named checkpoints.
Files
Files in the repository directory.
Bytes
Bytes of content.
Implementations§
Source§impl WorkUnit
impl WorkUnit
Sourcepub fn plural_noun(self) -> &'static str
pub fn plural_noun(self) -> &'static str
The plural noun a report uses for this unit, for example
"archives". WorkUnit::Bytes is "bytes"; a renderer that
scales byte counts substitutes its own scaled suffix.
Sourcepub fn singular_noun(self) -> &'static str
pub fn singular_noun(self) -> &'static str
The singular noun, for a report of exactly one item.
Trait Implementations§
impl Copy for WorkUnit
impl Eq for WorkUnit
impl StructuralPartialEq for WorkUnit
Auto Trait Implementations§
impl Freeze for WorkUnit
impl RefUnwindSafe for WorkUnit
impl Send for WorkUnit
impl Sync for WorkUnit
impl Unpin for WorkUnit
impl UnsafeUnpin for WorkUnit
impl UnwindSafe for WorkUnit
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