1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
//! This applications crate is a library crate that can be used to get a list of installed applications on your system.
//! Support MacOS, and Linux. Windows support will be added soon.
//!
//! # Examples
//!
//! ```ignore
//! let mut ctx = crate::common::AppInfoContext::new();
//! ctx.refresh_apps().unwrap(); // this will block the thread
//! let apps = ctx.get_all_apps();
//! assert!(apps.len() > 0);
//! ```
//!
//! ```ignore
//! use applications::{AppInfoContext, AppInfo};
//!
//! fn main() {
//! let mut ctx = AppInfoContext::new();
//! ctx.refresh_apps().unwrap(); // must refresh apps before getting them
//! let apps = ctx.get_all_apps();
//! println!("Apps: {:#?}", apps);
//! let frontmost_app = ctx.get_frontmost_application().unwrap();
//! println!("Frontmost App: {:#?}", frontmost_app);
//! let running_apps = ctx.get_running_apps();
//! println!("Running Apps: {:#?}", running_apps);
//! }
//! ```
// difference platforms may have different implementation and signatures for each function, so platforms will not be public
pub use ;
pub use ;