pub struct ModuleResult {
pub name: Option<String>,
pub per_language: HashMap<String, Stats>,
pub nested_languages: HashMap<String, HashMap<String, Stats>>,
pub files: HashMap<String, Vec<FileEntry>>,
pub total: Stats,
}Expand description
One module and its own figures. A module is a target that was given a name, as in
mezura frontend=./web backend=./api.
Fields§
§name: Option<String>None for everything the named targets left over, which on a run where nothing was named
is the whole of it.
per_language: HashMap<String, Stats>This module’s languages.
nested_languages: HashMap<String, HashMap<String, Stats>>The same breakdown RunResult::nested_languages holds, for this module’s files alone.
files: HashMap<String, Vec<FileEntry>>One entry per file, keyed by language. Empty unless crate::EngineConfig::collect_files
asked for it.
total: StatsThis module’s languages added together.
Implementations§
Source§impl ModuleResult
impl ModuleResult
Sourcepub fn sort_languages_by(
&self,
criterion: SortCriterion,
model: CountingModel,
) -> Vec<(&str, &Stats)>
pub fn sort_languages_by( &self, criterion: SortCriterion, model: CountingModel, ) -> Vec<(&str, &Stats)>
The languages largest first by the chosen figure, ties broken by name.
Trait Implementations§
Source§impl Clone for ModuleResult
impl Clone for ModuleResult
Source§fn clone(&self) -> ModuleResult
fn clone(&self) -> ModuleResult
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for ModuleResult
impl RefUnwindSafe for ModuleResult
impl Send for ModuleResult
impl Sync for ModuleResult
impl Unpin for ModuleResult
impl UnsafeUnpin for ModuleResult
impl UnwindSafe for ModuleResult
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