pub struct Machine {
pub os: String,
pub os_version: Option<String>,
pub kernel: Option<String>,
pub arch: String,
pub cpu: Option<String>,
pub cpus: Option<usize>,
pub memory_bytes: Option<u64>,
}Fields§
§os: StringAs Rust names it: linux, macos, windows.
os_version: Option<String>The distribution or product version: /etc/os-release’s
PRETTY_NAME on Linux, 15.3.1 on macOS. None on Windows, whose
registry names Windows 11 as Windows 10; kernel has the build.
kernel: Option<String>Kernel release: 6.8.0-45-generic on Linux, the Darwin release on
macOS, 10.0.<build> on Windows.
arch: StringAs Rust names it: x86_64, aarch64.
cpu: Option<String>The CPU’s model name, as the vendor brands it.
cpus: Option<usize>Logical CPUs tak — and so every subject — could run on. Not the
machine’s total: on Linux this honours the CPU affinity mask (taskset,
a container’s cpuset) and a cgroup CPU quota, which is what bounds a
parallel tool’s speed-up.
memory_bytes: Option<u64>Total physical memory in bytes.
Trait Implementations§
impl Eq for Machine
impl StructuralPartialEq for Machine
Auto Trait Implementations§
impl Forget for Machine
impl Freeze for Machine
impl Move for Machine
impl RefUnwindSafe for Machine
impl Send for Machine
impl Sync for Machine
impl Unpin for Machine
impl UnsafeUnpin for Machine
impl UnwindSafe for Machine
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> 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§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
Compare self to
key and return true if they are equal.