Crate sysinfo

Crate sysinfo 

Source
Expand description

For crate-level documentation, all features need to be enabled.

Structs§

CGroupLimits
Contains memory limits for the current process.
Cpu
Contains all the methods of the Cpu struct.
CpuRefreshKind
Used to determine what you want to refresh specifically on the Cpu type.
DiskUsage
Type containing read and written bytes.
Gid
A group id wrapping a platform specific type.
LoadAvg
A struct representing system load average value.
MemoryRefreshKind
Used to determine which memory you want to refresh specifically.
Pid
Process ID.
Process
Struct containing information of a process.
ProcessRefreshKind
Used to determine what you want to refresh specifically on the Process type.
RefreshKind
Used to determine what you want to refresh specifically on the System type.
System
Structs containing system’s information such as processes, memory and CPU.
Uid
A user id wrapping a platform specific type.

Enums§

ProcessStatus
Enum describing the different status of a process.
ProcessesToUpdate
This enum allows you to specify if you want all processes to be updated or just some of them.
Signal
An enum representing signals on UNIX-like systems.
ThreadKind
Enum describing the different kind of threads.
UpdateKind
This enum allows you to specify when you want the related information to be updated.

Constants§

IS_SUPPORTED_SYSTEM
Returns true if this OS is supported. Please refer to the crate-level documentation to get the list of supported OSes.
MINIMUM_CPU_UPDATE_INTERVAL
This is the minimum interval time used internally by sysinfo to refresh the CPU time.
SUPPORTED_SIGNALS
Returns the list of the supported signals on this system (used by Process::kill_with).

Functions§

get_current_pid
Returns the pid for the current process.
set_open_files_limit
This function is only used on Linux targets, when the system feature is enabled. In other cases, it does nothing and returns false.