[−][src]Struct bitvec::indices::BitIdx
Indicates a semantic index of a bit within a memory element.
This type is consumed by Cursor
implementors, which use it to produce a
concrete bit position inside an element.
BitIdx
is a semantic counter which has a defined, constant, and predictable
ordering. Values of BitIdx
refer strictly to an abstract ordering, and not to
any actual bit positions within a memory element, so BitIdx::<T>(0)
is always
the first bit counted within an element, but is not required to be the most or
least significant bits, or any other particular bits. Which specific bit is
referred by a BitIdx
value is governed by implementors of Cursor
.
Type Parameters
T
: The memory element type controlled by this index.
Trait Implementations
impl<T: Clone> Clone for BitIdx<T> where
T: BitStore,
[src]
T: BitStore,
impl<T: Copy> Copy for BitIdx<T> where
T: BitStore,
[src]
T: BitStore,
impl<T: Default> Default for BitIdx<T> where
T: BitStore,
[src]
T: BitStore,
impl<T: Eq> Eq for BitIdx<T> where
T: BitStore,
[src]
T: BitStore,
impl<T: Ord> Ord for BitIdx<T> where
T: BitStore,
[src]
T: BitStore,
fn cmp(&self, other: &BitIdx<T>) -> Ordering
[src]
fn max(self, other: Self) -> Self
1.21.0[src]
fn min(self, other: Self) -> Self
1.21.0[src]
fn clamp(self, min: Self, max: Self) -> Self
[src]
impl<T: PartialEq> PartialEq<BitIdx<T>> for BitIdx<T> where
T: BitStore,
[src]
T: BitStore,
impl<T: PartialOrd> PartialOrd<BitIdx<T>> for BitIdx<T> where
T: BitStore,
[src]
T: BitStore,
fn partial_cmp(&self, other: &BitIdx<T>) -> Option<Ordering>
[src]
fn lt(&self, other: &BitIdx<T>) -> bool
[src]
fn le(&self, other: &BitIdx<T>) -> bool
[src]
fn gt(&self, other: &BitIdx<T>) -> bool
[src]
fn ge(&self, other: &BitIdx<T>) -> bool
[src]
impl<T: Debug> Debug for BitIdx<T> where
T: BitStore,
[src]
T: BitStore,
impl<T> TryFrom<u8> for BitIdx<T> where
T: BitStore,
[src]
T: BitStore,
type Error = &'static str
The type returned in the event of a conversion error.
fn try_from(idx: u8) -> Result<Self, Self::Error>
[src]
impl<T> Deref for BitIdx<T> where
T: BitStore,
[src]
T: BitStore,
impl<T: Hash> Hash for BitIdx<T> where
T: BitStore,
[src]
T: BitStore,
fn hash<__H: Hasher>(&self, state: &mut __H)
[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
impl<T> StructuralPartialEq for BitIdx<T> where
T: BitStore,
[src]
T: BitStore,
impl<T> StructuralEq for BitIdx<T> where
T: BitStore,
[src]
T: BitStore,
Auto Trait Implementations
impl<T> Send for BitIdx<T>
impl<T> Sync for BitIdx<T>
impl<T> Unpin for BitIdx<T> where
T: Unpin,
T: Unpin,
impl<T> UnwindSafe for BitIdx<T> where
T: UnwindSafe,
T: UnwindSafe,
impl<T> RefUnwindSafe for BitIdx<T> where
T: RefUnwindSafe,
T: RefUnwindSafe,
Blanket Implementations
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
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.
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>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,