[−][src]Struct heim_host::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
Auto Trait Implementations
impl RefUnwindSafe for Platform
[src]
impl Send for Platform
[src]
impl Sync for Platform
[src]
impl Unpin for Platform
[src]
impl UnwindSafe for Platform
[src]
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
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]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,