Enum hwlocality::object::depth::Depth
source · pub enum Depth {
Normal(NormalDepth),
NUMANode,
Bridge,
PCIDevice,
OSDevice,
Misc,
MemCache,
}
Expand description
Valid object/type depth values
See the module-level documentation for context.
Variants§
Normal(NormalDepth)
Depth of a normal object (not Memory, I/O or Misc)
NUMANode
Virtual depth for ObjectType::NUMANode
Bridge
Virtual depth for ObjectType::Bridge
PCIDevice
Virtual depth for ObjectType::PCIDevice
OSDevice
Virtual depth for ObjectType::OSDevice
Misc
Virtual depth for ObjectType::Misc
MemCache
Available on crate feature
hwloc-2_1_0
only.Virtual depth for ObjectType::MemCache
Implementations§
source§impl Depth
impl Depth
sourcepub fn expect_normal(self) -> NormalDepth
pub fn expect_normal(self) -> NormalDepth
Assert that this should be a normal object depth, panicking if it turns out not to be the case.
sourcepub const VIRTUAL_DEPTHS: &'static [Self] = _
pub const VIRTUAL_DEPTHS: &'static [Self] = _
List of virtual depths
sourcepub const MEMORY_DEPTHS: &'static [Self] = _
pub const MEMORY_DEPTHS: &'static [Self] = _
List of memory object virtual depths
Trait Implementations§
source§impl Arbitrary for Depth
Available on crate feature proptest
only.
impl Arbitrary for Depth
Available on crate feature
proptest
only.§type Parameters = <PositiveInt as Arbitrary>::Parameters
type Parameters = <PositiveInt as Arbitrary>::Parameters
The type of parameters that
arbitrary_with
accepts for configuration
of the generated Strategy
. Parameters must implement Default
.§type Strategy = TupleUnion<((u32, Arc<Map<<PositiveInt as Arbitrary>::Strategy, fn(_: PositiveInt) -> Depth>>), (u32, Arc<Select<Depth>>))>
type Strategy = TupleUnion<((u32, Arc<Map<<PositiveInt as Arbitrary>::Strategy, fn(_: PositiveInt) -> Depth>>), (u32, Arc<Select<Depth>>))>
The type of
Strategy
used to generate values of type Self
.source§fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
source§impl From<PositiveInt> for Depth
impl From<PositiveInt> for Depth
source§fn from(value: NormalDepth) -> Self
fn from(value: NormalDepth) -> Self
Converts to this type from the input type.
source§impl PartialEq<Depth> for NormalDepth
impl PartialEq<Depth> for NormalDepth
source§impl PartialEq<Depth> for usize
impl PartialEq<Depth> for usize
source§impl PartialEq<PositiveInt> for Depth
impl PartialEq<PositiveInt> for Depth
source§fn eq(&self, other: &NormalDepth) -> bool
fn eq(&self, other: &NormalDepth) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl PartialEq<usize> for Depth
impl PartialEq<usize> for Depth
source§impl PartialEq for Depth
impl PartialEq for Depth
source§impl TryFrom<Depth> for NormalDepth
impl TryFrom<Depth> for NormalDepth
source§impl TryFrom<usize> for Depth
impl TryFrom<usize> for Depth
§type Error = TryFromIntError
type Error = TryFromIntError
The type returned in the event of a conversion error.
impl Copy for Depth
impl Eq for Depth
impl StructuralPartialEq for Depth
Auto Trait Implementations§
impl Freeze for Depth
impl RefUnwindSafe for Depth
impl Send for Depth
impl Sync for Depth
impl Unpin for Depth
impl UnwindSafe for Depth
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