pub struct Overview {
pub total: usize,
pub visible: usize,
pub success: usize,
pub failed: usize,
pub projects: usize,
pub top_shell: Option<String>,
}Expand description
Indicateurs agrégés affichés dans la barre de synthèse (« overview »).
Tous les indicateurs hormis total sont calculés sur les commandes
visibles (après recherche et filtres). total reflète l’ensemble
chargé en mémoire avant filtres. Les compteurs sont cohérents :
success + failed == visible.
Fields§
§total: usizeNombre total de commandes chargées (avant filtres).
visible: usizeCommandes visibles après filtres et recherche.
success: usizeVisibles n’ayant pas échoué (exit_code == 0 ou inconnu).
failed: usizeVisibles terminées en échec (exit_code présent et ≠ 0).
projects: usizeProjets Git distincts parmi les commandes visibles.
top_shell: Option<String>Shell dominant parmi les commandes visibles, le cas échéant.
Implementations§
Source§impl Overview
impl Overview
Sourcepub fn compute(records: &[CommandRecord], filtered: &[usize]) -> Self
pub fn compute(records: &[CommandRecord], filtered: &[usize]) -> Self
Calcule les indicateurs à partir des commandes et des indices visibles.
Seuls les indices présents dans filtered (les commandes visibles)
alimentent visible, success, failed, projects et top_shell.
total reste l’ensemble chargé. Un échec est une commande dont le
exit_code est présent et différent de zéro ; tout le reste (succès
explicite ou statut inconnu) compte comme succès, de sorte que
success + failed == visible.
Sourcepub fn failure_rate(&self) -> f64
pub fn failure_rate(&self) -> f64
Taux d’échec parmi les commandes visibles (0.0 à 100.0).
Renvoie 0.0 si aucune commande n’est visible.
Trait Implementations§
impl Eq for Overview
impl StructuralPartialEq for Overview
Auto Trait Implementations§
impl Freeze for Overview
impl RefUnwindSafe for Overview
impl Send for Overview
impl Sync for Overview
impl Unpin for Overview
impl UnsafeUnpin for Overview
impl UnwindSafe for Overview
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.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>
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>
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 more