[][src]Enum sysctl::CtlType

#[repr(u32)]pub enum CtlType {
    Node,
    Int,
    String,
    S64,
    Struct,
    Uint,
    Long,
    Ulong,
    U64,
    U8,
    U16,
    S8,
    S16,
    S32,
    U32,
    None,
    Temperature,
}

An Enum that represents a sysctl's type information.

Example

This example is not tested
let val_enum = &sysctl::value("kern.osrevision").unwrap();
let val_type: sysctl::CtlType = val_enum.into();
assert_eq!(val_type, sysctl::CtlType::Int);

Variants

Node
Int
String
S64
Struct
Uint
Long
Ulong
U64
U8
U16
S8
S16
S32
U32
None
Temperature

Implementations

impl CtlType[src]

pub fn min_type_size(&self) -> usize[src]

Trait Implementations

impl Clone for CtlType[src]

impl Copy for CtlType[src]

impl Debug for CtlType[src]

impl<'a> From<&'a CtlValue> for CtlType[src]

impl From<u32> for CtlType[src]

impl PartialEq<CtlType> for CtlType[src]

impl StructuralPartialEq for CtlType[src]

Auto Trait Implementations

impl RefUnwindSafe for CtlType

impl Send for CtlType

impl Sync for CtlType

impl Unpin for CtlType

impl UnwindSafe for CtlType

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> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

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.