[][src]Struct heim_host::Platform

pub struct Platform(_);

Host system information.

Provided information

For example, for Linux host command uname -a returns the following line:

$ uname -a
Linux tardis 5.0.5-arch1-1-ARCH #1 SMP PREEMPT Wed Mar 27 17:53:10 UTC 2019 x86_64 GNU/Linux

Information in this struct for the same host will look like this:

Platform {
   system: "Linux",
   release: "5.0.5-arch1-1-ARCH",
   version: "#1 SMP PREEMPT Wed Mar 27 17:53:10 UTC 2019",
   hostname: "tardis",
   architecture: X86_64,
}

Windows example:

Platform {
    system: "Windows",
    release: "10",
    version: "17763",
    hostname: "WINDEV1905EVAL",
    architecture: X86_64,
}

Implementations

impl Platform[src]

pub fn system(&self) -> &str[src]

Returns system name.

pub fn release(&self) -> &str[src]

Returns system release.

pub fn version(&self) -> &str[src]

Returns system version.

pub fn hostname(&self) -> &str[src]

Returns system hostname.

pub fn architecture(&self) -> Arch[src]

Returns system architecture.

Trait Implementations

impl Debug for Platform[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.