pub struct ElectronManager { /* private fields */ }Expand description
Electron app manager
Implementations§
Source§impl ElectronManager
impl ElectronManager
pub fn new() -> Self
Sourcepub fn get_apps(&self) -> Vec<&ElectronAppInfo>
pub fn get_apps(&self) -> Vec<&ElectronAppInfo>
Get all detected Electron apps
Sourcepub fn get_app(&self, name: &str) -> Option<&ElectronAppInfo>
pub fn get_app(&self, name: &str) -> Option<&ElectronAppInfo>
Get app by name
Sourcepub fn total_memory_mb(&self) -> f64
pub fn total_memory_mb(&self) -> f64
Get total Electron app memory
Sourcepub fn get_bloated_apps(&self) -> Vec<&ElectronAppInfo>
pub fn get_bloated_apps(&self) -> Vec<&ElectronAppInfo>
Get apps that are bloated
Sourcepub fn get_suggestions(&self) -> Vec<(String, OptimizationAction, String)>
pub fn get_suggestions(&self) -> Vec<(String, OptimizationAction, String)>
Get optimization suggestions
Sourcepub fn print_summary(&self)
pub fn print_summary(&self)
Print Electron apps summary
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ElectronManager
impl RefUnwindSafe for ElectronManager
impl Send for ElectronManager
impl Sync for ElectronManager
impl Unpin for ElectronManager
impl UnwindSafe for ElectronManager
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> 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 more