MCPcopy Create free account

hub / github.com/GuillaumeGomez/sysinfo / functions

Functions1,805 in github.com/GuillaumeGomez/sysinfo

↓ 3 callersMethodrefresh_memory_specifics
Refreshes system memory specific information. ```no_run use sysinfo::{MemoryRefreshKind, System}; if let Ok(mut s) = System::new() { s.refresh_memor
src/common/system.rs:170
↓ 3 callersMethodrefresh_specifics
Updates the disk's information corresponding to the given [`DiskRefreshKind`]. ```no_run use sysinfo::{Disks, DiskRefreshKind}; if let Ok(mut disks)
src/common/disk.rs:193
↓ 3 callersMethodrefresh_specifics
Refreshes according to the given [`RefreshKind`]. It calls the corresponding "refresh_" methods. It will remove dead processes if [`RefreshKind::proc
src/common/system.rs:111
↓ 3 callersMethodroot
(&self)
src/windows/process.rs:442
↓ 3 callersFunctionshould_skip
()
tests/disk.rs:13
↓ 3 callersFunctionto_c_string
(path: PathBuf)
src/unix/linux/process.rs:1564
↓ 3 callersMethodtotal_memory
Returns the total VRAM of this GPU in bytes. ⚠️ It does not take into account the GPU memory that is shared with the system's RAM. On macOS, GPUs sh
src/common/gpu.rs:278
↓ 3 callersMethodtotal_swap
Returns the SWAP size in bytes. ```no_run use sysinfo::System; if let Ok(s) = System::new_all() { println!("{} bytes", s.total_swap()); } ```
src/common/system.rs:690
↓ 3 callersMethodused_memory
Returns the used VRAM of this GPU in bytes. ⚠️ It does not take into account the GPU memory that is shared with the system's RAM. On macOS, GPUs sha
src/common/gpu.rs:289
↓ 3 callersFunctionwait_process
(pid: crate::Pid)
src/unix/utils.rs:45
↓ 2 callersFunction_get_stat_data
Reads the `stat` file into `buffers.buf`.
src/unix/linux/process.rs:975
↓ 2 callersMethodaccumulated_cpu_time
Returns the total accumulated CPU usage (in CPU-milliseconds). Note that it might be bigger than the total clock run time of a process if run on a mul
src/common/system.rs:2090
↓ 2 callersMethodadd_english_counter
(&mut self, name: &str)
src/windows/cpu.rs:179
↓ 2 callersMethodasset_tag
Returns the motherboard asset tag. This corresponds to the identifier assigned by the motherboard's manufacturer to track the physical device for inv
src/common/system.rs:1140
↓ 2 callersFunctionboot_time
()
src/unix/apple/system.rs:100
↓ 2 callersFunctionboot_time
()
src/unix/linux/system.rs:76
↓ 2 callersMethodbrand
(&self)
src/windows/cpu.rs:316
↓ 2 callersFunctionbuild_requested_properties
( properties: &[Option<&CFString>], )
src/unix/apple/disk.rs:366
↓ 2 callersFunctionc_buf_to_os_string
(buf: &[libc::c_char])
src/unix/bsd/netbsd/utils.rs:71
↓ 2 callersFunctionc_buf_to_utf8_str
(buf: &[libc::c_char])
src/unix/bsd/netbsd/utils.rs:39
↓ 2 callersFunctioncheck
(_: T)
src/common/system.rs:3174
↓ 2 callersFunctioncheck_sub
(a: u64, b: u64)
src/windows/process.rs:1135
↓ 2 callersMethodcmd
(&self)
src/unix/bsd/system_common.rs:78
↓ 2 callersMethodcmd
(&self)
src/windows/process.rs:422
↓ 2 callersFunctioncompute_cpu_usage
(p: &mut ProcessInner, total_time: f32, max_value: f32)
src/unix/linux/process.rs:757
↓ 2 callersFunctioncompute_gpu_usage
Maybe something to do in the future: if it's not an AMD or NVIDIA GPU, we can still compute the total % usage by adding all processes GPU time. Howeve
src/unix/linux/process.rs:592
↓ 2 callersFunctioncompute_usage_of_cpu
(proc_: &Cpu, cpu_info: *mut i32, offset: isize)
src/unix/apple/cpu.rs:243
↓ 2 callersMethodconnect_server
(mut self)
src/windows/component.rs:207
↓ 2 callersFunctionconvert_to_string
(data: &[libc::c_char])
src/unix/linux/gpu.rs:332
↓ 2 callersFunctioncpuinfo_is_key
(line: &str, key: &[u8])
src/unix/linux/cpu.rs:823
↓ 2 callersMethodcpus
Returns the list of the CPUs. By default, the list of CPUs is empty until you call [`System::refresh_cpu_specifics`] or [`System::refresh_specifics`]
src/common/system.rs:610
↓ 2 callersMethodcreate_instance
(mut self)
src/windows/component.rs:200
↓ 2 callersFunctioncstr_to_rust
(c: *const libc::c_char)
src/unix/utils.rs:4
↓ 2 callersFunctioncstr_to_rust_with_size
( c: *const libc::c_char, size: Option<usize>, )
src/unix/utils.rs:10
↓ 2 callersMethodcwd
(&self)
src/unix/bsd/system_common.rs:98
↓ 2 callersMethodcwd
(&self)
src/windows/process.rs:438
↓ 2 callersMethodcwd
Returns the current working directory. ```no_run use sysinfo::{Pid, System}; if let Ok(s) = System::new_all() && let Some(process) = s.process(Pid::
src/common/system.rs:1904
↓ 2 callersFunctiondecode_mountinfo_path
The kernel renders mountinfo root and mount point fields with octal escapes for space, tab, newline and backslash (seq_escape() via show_mountinfo() i
src/unix/linux/cgroup.rs:443
↓ 2 callersMethoddir_fd
(&mut self)
src/unix/linux/process.rs:867
↓ 2 callersFunctiondisk_stats
(refresh_kind: &DiskRefreshKind)
src/unix/linux/disk.rs:485
↓ 2 callersMethoddisk_usage
(&self)
src/unix/apple/macos/process.rs:213
↓ 2 callersMethoddisk_usage
Returns number of bytes read and written to disk. ⚠️ On Windows, this method actually returns **ALL** I/O read and written bytes. ⚠️ Files might be
src/common/system.rs:2120
↓ 2 callersMethodenviron
(&self)
src/unix/bsd/system_common.rs:94
↓ 2 callersMethodenviron
(&self)
src/windows/process.rs:434
↓ 2 callersMethodexe
(&self)
src/unix/bsd/system_common.rs:82
↓ 2 callersMethodexe
(&self)
src/unix/apple/macos/process.rs:154
↓ 2 callersMethodexe
Returns the path to the process. ```no_run use sysinfo::{Pid, System}; if let Ok(s) = System::new_all() && let Some(process) = s.process(Pid::from(1
src/common/system.rs:1839
↓ 2 callersMethodexec_query
(mut self)
src/windows/component.rs:244
↓ 2 callersFunctionfiletime_to_u64
(ft: FILETIME)
src/windows/process.rs:1219
↓ 2 callersFunctionfill_component
Check given `item` dispatch to read the right `file` with the right parsing and store data in given `component`. `id` is provided for `label` creation
src/unix/linux/component.rs:215
↓ 2 callersMethodfree_memory
Returns the amount of free RAM in bytes. Generally, "free" memory refers to unallocated memory whereas "available" memory refers to memory that is av
src/common/system.rs:645
↓ 2 callersMethodfree_swap
Returns the amount of free SWAP in bytes. ```no_run use sysinfo::System; if let Ok(s) = System::new_all() { println!("{} bytes", s.free_swap()); } `
src/common/system.rs:703
↓ 2 callersMethodfrequency
(&self)
src/unix/apple/cpu.rs:188
↓ 2 callersFunctionfrom_zero_terminated
Creates a copy of the first zero-terminated wide string in `buf`. The copy includes the zero terminator.
src/windows/disk.rs:30
↓ 2 callersFunctionget_available_volume_space
(disk_props: &CFDictionary)
src/unix/apple/disk.rs:386
↓ 2 callersFunctionget_bool_value
(dict: &CFDictionary, key: Option<&CFString>)
src/unix/apple/disk.rs:424
↓ 2 callersFunctionget_cmdline_from_buffer
(buffer: PCWSTR)
src/windows/process.rs:735
↓ 2 callersFunctionget_cpu_frequency
(#[allow(unused_variables)] brand: &str)
src/unix/apple/cpu.rs:201
↓ 2 callersFunctionget_cpu_frequency
(cpu_core_index: usize)
src/unix/linux/cpu.rs:450
↓ 2 callersFunctionget_cwd_root
(process: &mut ProcessInner, refresh_kind: ProcessRefreshKind)
src/unix/apple/macos/process.rs:557
↓ 2 callersFunctionget_disk_properties
( volume_url: &CFURL, requested_properties: &CFArray, )
src/unix/apple/disk.rs:379
↓ 2 callersFunctionget_exe_and_name_backup
Less efficient way to retrieve `exe` and `name`.
src/unix/apple/macos/process.rs:511
↓ 2 callersFunctionget_frequencies
From https://stackoverflow.com/a/43813138: If your PC has 64 or fewer logical cpus installed, the above code will work fine. However, if your PC has
src/windows/cpu.rs:468
↓ 2 callersFunctionget_groups
(groups: &mut Vec<crate::Group>)
src/unix/groups.rs:20
↓ 2 callersFunctionget_id_and_name
(line: &str)
src/unix/linux/gpu.rs:267
↓ 2 callersFunctionget_interface_address
()
src/windows/network_helper.rs:101
↓ 2 callersMethodget_kd
(&mut self)
src/unix/bsd/freebsd/system.rs:530
↓ 2 callersFunctionget_key_size
(con: io_connect_t, key: &[i8])
src/unix/apple/macos/component/x86.rs:220
↓ 2 callersFunctionget_key_used
(p: &mut Cpu)
src/windows/cpu.rs:459
↓ 2 callersFunctionget_nb_cpus
()
src/unix/bsd/freebsd/utils.rs:216
↓ 2 callersFunctionget_nb_cpus
()
src/unix/bsd/netbsd/utils.rs:242
↓ 2 callersMethodget_new
(&self)
src/unix/bsd/netbsd/cpu.rs:237
↓ 2 callersFunctionget_parent
(info: &libc::proc_bsdinfo)
src/unix/apple/macos/process.rs:436
↓ 2 callersFunctionget_process_data
( kproc: &libc::kinfo_proc2, wrap: &WrapMap, now: u64, refresh_kind: ProcessRefreshKind, s
src/unix/bsd/netbsd/process.rs:205
↓ 2 callersFunctionget_process_infos
(process: &mut ProcessInner, refresh_kind: ProcessRefreshKind)
src/unix/apple/macos/process.rs:585
↓ 2 callersFunctionget_processes_gpu_usage
(processes: &mut HashMap<Pid, Process>)
src/unix/apple/system.rs:676
↓ 2 callersFunctionget_str_value
(dict: &CFDictionary, key: Option<&CFString>)
src/unix/apple/disk.rs:415
↓ 2 callersFunctionget_sys_value_str
( mib: &[libc::c_int], buf: &mut [libc::c_char], )
src/unix/bsd/freebsd/utils.rs:109
↓ 2 callersFunctionget_sys_value_str_by_name
(name: &[u8])
src/unix/bsd/freebsd/utils.rs:150
↓ 2 callersFunctionget_sysctl_str
(s: &[u8])
src/unix/apple/cpu.rs:350
↓ 2 callersFunctionget_task_info
(pid: Pid)
src/unix/apple/macos/process.rs:382
↓ 2 callersFunctionget_temperature_from_file
(file: &Path)
src/unix/linux/component.rs:168
↓ 2 callersFunctionget_temperature_inner
( con: io_connect_t, input_structure: &ffi::KeyData_t, original_val: &ffi::Val_t, )
src/unix/apple/macos/component/x86.rs:278
↓ 2 callersMethodget_time_interval
(&mut self, port: mach_port_t)
src/unix/apple/macos/system.rs:113
↓ 2 callersFunctionget_uid_and_gid_and_tgid
Fetch real and effective UID and GID and store them into `Pids`. Returns the "thread group id" (tgid) as second value of the tuple.
src/unix/linux/process.rs:1615
↓ 2 callersMethodget_value
( &self, field_name: &[u16], buf: &mut [u8], buf_len: &mut u32, )
src/windows/system.rs:586
↓ 2 callersMethodgpu_memory
(&self)
src/windows/process.rs:619
↓ 2 callersMethodgpu_usage
(&self)
src/windows/process.rs:614
↓ 2 callersMethodgroup_id
(&self)
src/unix/users.rs:32
↓ 2 callersMethodid
Returns the ID of the user. ```no_run use sysinfo::Users; if let Ok(users) = Users::new_with_refreshed_list() { for user in &users { println!("{:?}"
src/common/user.rs:58
↓ 2 callersFunctioninner
(system: &mut System)
tests/process.rs:217
↓ 2 callersMethodinner_mut
(&mut self)
src/windows/users.rs:90
↓ 2 callersMethodinner_mut_as_bytes
(&mut self)
src/windows/users.rs:95
↓ 2 callersFunctionipv6_mask_to_prefix
(mask: Ipv6Addr)
src/unix/network_helper.rs:288
↓ 2 callersFunctioniterate_service_tree
(bsd_name: &[u8], key: &CFString, eval: F)
src/unix/apple/macos/disk.rs:17
↓ 2 callersMethodkind
(&self)
src/unix/linux/disk.rs:79
↓ 2 callersMethodlength
(&self)
src/windows/ffi.rs:62
↓ 2 callersMethodload
()
src/unix/linux/gpu.rs:409
↓ 2 callersFunctionmach_task_self
()
src/unix/apple/ffi.rs:20
↓ 2 callersMethodmax
(&self)
src/unix/linux/component.rs:355
← previousnext →101–200 of 1,805, ranked by callers