pub struct NetId { /* private fields */ }Implementations§
Source§impl NetId
impl NetId
Sourcepub const MAX_INDEX: usize = 65_535usize
pub const MAX_INDEX: usize = 65_535usize
If Self::CHECKS_MAX_INDEX is true, we’ll assert if trying to
produce a value larger than this in any of the ctors that don’t
have unchecked in their name.
Sourcepub const CHECKS_MAX_INDEX: bool = true
pub const CHECKS_MAX_INDEX: bool = true
Does this index type assert if asked to construct an index larger than MAX_INDEX?
Sourcepub fn from_foreign<F: Idx>(value: F) -> Self
pub fn from_foreign<F: Idx>(value: F) -> Self
Construct this index type from one in a different domain
Sourcepub const fn from_usize_unchecked(value: usize) -> Self
pub const fn from_usize_unchecked(value: usize) -> Self
Construct from a usize without any checks.
Sourcepub const fn from_raw_unchecked(raw: u16) -> Self
pub const fn from_raw_unchecked(raw: u16) -> Self
Construct from the underlying type without any checks.
Sourcepub fn from_usize(value: usize) -> Self
pub fn from_usize(value: usize) -> Self
Construct this index type from a usize.
Sourcepub fn check_index(v: usize)
pub fn check_index(v: usize)
Asserts v <= Self::MAX_INDEX unless Self::CHECKS_MAX_INDEX is false.
Trait Implementations§
Source§impl AddAssign<usize> for NetId
impl AddAssign<usize> for NetId
Source§fn add_assign(&mut self, other: usize)
fn add_assign(&mut self, other: usize)
Performs the
+= operation. Read moreSource§impl AddAssign for NetId
impl AddAssign for NetId
Source§fn add_assign(&mut self, other: NetId)
fn add_assign(&mut self, other: NetId)
Performs the
+= operation. Read moreSource§impl Ord for NetId
impl Ord for NetId
Source§impl PartialOrd<NetId> for usize
impl PartialOrd<NetId> for usize
Source§impl PartialOrd<usize> for NetId
impl PartialOrd<usize> for NetId
Source§impl PartialOrd for NetId
impl PartialOrd for NetId
Source§impl SubAssign<usize> for NetId
impl SubAssign<usize> for NetId
Source§fn sub_assign(&mut self, other: usize)
fn sub_assign(&mut self, other: usize)
Performs the
-= operation. Read moreSource§impl SubAssign for NetId
impl SubAssign for NetId
Source§fn sub_assign(&mut self, other: NetId)
fn sub_assign(&mut self, other: NetId)
Performs the
-= operation. Read moreimpl Copy for NetId
impl Eq for NetId
impl StructuralPartialEq for NetId
Auto Trait Implementations§
impl Freeze for NetId
impl RefUnwindSafe for NetId
impl Send for NetId
impl Sync for NetId
impl Unpin for NetId
impl UnwindSafe for NetId
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§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.