Struct FixedBitSet
pub struct FixedBitSet<const BIT_COUNT: usize, const BYTE_COUNT: usize>(pub [u8; BYTE_COUNT]);Expand description
A fixed-size bit set encoded as a byte array.
Minecraft’s protocol calls this type Fixed BitSet(n). Bits are addressed
from the least-significant bit of the first byte.
Tuple Fields§
§0: [u8; BYTE_COUNT]Implementations§
§impl<const BIT_COUNT: usize, const BYTE_COUNT: usize> FixedBitSet<BIT_COUNT, BYTE_COUNT>
impl<const BIT_COUNT: usize, const BYTE_COUNT: usize> FixedBitSet<BIT_COUNT, BYTE_COUNT>
Trait Implementations§
§impl<const BIT_COUNT: usize, const BYTE_COUNT: usize> Clone for FixedBitSet<BIT_COUNT, BYTE_COUNT>
impl<const BIT_COUNT: usize, const BYTE_COUNT: usize> Clone for FixedBitSet<BIT_COUNT, BYTE_COUNT>
§fn clone(&self) -> FixedBitSet<BIT_COUNT, BYTE_COUNT>
fn clone(&self) -> FixedBitSet<BIT_COUNT, BYTE_COUNT>
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read more§impl<const BIT_COUNT: usize, const BYTE_COUNT: usize> Debug for FixedBitSet<BIT_COUNT, BYTE_COUNT>
impl<const BIT_COUNT: usize, const BYTE_COUNT: usize> Debug for FixedBitSet<BIT_COUNT, BYTE_COUNT>
§impl<const BIT_COUNT: usize, const BYTE_COUNT: usize> Decode<'_> for FixedBitSet<BIT_COUNT, BYTE_COUNT>
impl<const BIT_COUNT: usize, const BYTE_COUNT: usize> Decode<'_> for FixedBitSet<BIT_COUNT, BYTE_COUNT>
§impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 0>
impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 0>
§fn default() -> FixedBitSet<BIT_COUNT, 0>
fn default() -> FixedBitSet<BIT_COUNT, 0>
Returns the “default value” for a type. Read more
§impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 1>
impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 1>
§fn default() -> FixedBitSet<BIT_COUNT, 1>
fn default() -> FixedBitSet<BIT_COUNT, 1>
Returns the “default value” for a type. Read more
§impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 10>
impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 10>
§fn default() -> FixedBitSet<BIT_COUNT, 10>
fn default() -> FixedBitSet<BIT_COUNT, 10>
Returns the “default value” for a type. Read more
§impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 11>
impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 11>
§fn default() -> FixedBitSet<BIT_COUNT, 11>
fn default() -> FixedBitSet<BIT_COUNT, 11>
Returns the “default value” for a type. Read more
§impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 12>
impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 12>
§fn default() -> FixedBitSet<BIT_COUNT, 12>
fn default() -> FixedBitSet<BIT_COUNT, 12>
Returns the “default value” for a type. Read more
§impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 13>
impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 13>
§fn default() -> FixedBitSet<BIT_COUNT, 13>
fn default() -> FixedBitSet<BIT_COUNT, 13>
Returns the “default value” for a type. Read more
§impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 14>
impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 14>
§fn default() -> FixedBitSet<BIT_COUNT, 14>
fn default() -> FixedBitSet<BIT_COUNT, 14>
Returns the “default value” for a type. Read more
§impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 15>
impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 15>
§fn default() -> FixedBitSet<BIT_COUNT, 15>
fn default() -> FixedBitSet<BIT_COUNT, 15>
Returns the “default value” for a type. Read more
§impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 16>
impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 16>
§fn default() -> FixedBitSet<BIT_COUNT, 16>
fn default() -> FixedBitSet<BIT_COUNT, 16>
Returns the “default value” for a type. Read more
§impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 2>
impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 2>
§fn default() -> FixedBitSet<BIT_COUNT, 2>
fn default() -> FixedBitSet<BIT_COUNT, 2>
Returns the “default value” for a type. Read more
§impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 3>
impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 3>
§fn default() -> FixedBitSet<BIT_COUNT, 3>
fn default() -> FixedBitSet<BIT_COUNT, 3>
Returns the “default value” for a type. Read more
§impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 4>
impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 4>
§fn default() -> FixedBitSet<BIT_COUNT, 4>
fn default() -> FixedBitSet<BIT_COUNT, 4>
Returns the “default value” for a type. Read more
§impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 5>
impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 5>
§fn default() -> FixedBitSet<BIT_COUNT, 5>
fn default() -> FixedBitSet<BIT_COUNT, 5>
Returns the “default value” for a type. Read more
§impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 6>
impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 6>
§fn default() -> FixedBitSet<BIT_COUNT, 6>
fn default() -> FixedBitSet<BIT_COUNT, 6>
Returns the “default value” for a type. Read more
§impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 7>
impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 7>
§fn default() -> FixedBitSet<BIT_COUNT, 7>
fn default() -> FixedBitSet<BIT_COUNT, 7>
Returns the “default value” for a type. Read more
§impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 8>
impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 8>
§fn default() -> FixedBitSet<BIT_COUNT, 8>
fn default() -> FixedBitSet<BIT_COUNT, 8>
Returns the “default value” for a type. Read more
§impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 9>
impl<const BIT_COUNT: usize> Default for FixedBitSet<BIT_COUNT, 9>
§fn default() -> FixedBitSet<BIT_COUNT, 9>
fn default() -> FixedBitSet<BIT_COUNT, 9>
Returns the “default value” for a type. Read more
§impl<const BIT_COUNT: usize, const BYTE_COUNT: usize> Display for FixedBitSet<BIT_COUNT, BYTE_COUNT>
impl<const BIT_COUNT: usize, const BYTE_COUNT: usize> Display for FixedBitSet<BIT_COUNT, BYTE_COUNT>
§impl<const BIT_COUNT: usize, const BYTE_COUNT: usize> Encode for FixedBitSet<BIT_COUNT, BYTE_COUNT>
impl<const BIT_COUNT: usize, const BYTE_COUNT: usize> Encode for FixedBitSet<BIT_COUNT, BYTE_COUNT>
§impl<const BIT_COUNT: usize, const BYTE_COUNT: usize> PartialEq for FixedBitSet<BIT_COUNT, BYTE_COUNT>
impl<const BIT_COUNT: usize, const BYTE_COUNT: usize> PartialEq for FixedBitSet<BIT_COUNT, BYTE_COUNT>
§fn eq(&self, other: &FixedBitSet<BIT_COUNT, BYTE_COUNT>) -> bool
fn eq(&self, other: &FixedBitSet<BIT_COUNT, BYTE_COUNT>) -> bool
Tests for
self and other values to be equal, and is used by ==.impl<const BIT_COUNT: usize, const BYTE_COUNT: usize> Copy for FixedBitSet<BIT_COUNT, BYTE_COUNT>
impl<const BIT_COUNT: usize, const BYTE_COUNT: usize> Eq for FixedBitSet<BIT_COUNT, BYTE_COUNT>
impl<const BIT_COUNT: usize, const BYTE_COUNT: usize> StructuralPartialEq for FixedBitSet<BIT_COUNT, BYTE_COUNT>
Auto Trait Implementations§
impl<const BIT_COUNT: usize, const BYTE_COUNT: usize> Freeze for FixedBitSet<BIT_COUNT, BYTE_COUNT>
impl<const BIT_COUNT: usize, const BYTE_COUNT: usize> RefUnwindSafe for FixedBitSet<BIT_COUNT, BYTE_COUNT>
impl<const BIT_COUNT: usize, const BYTE_COUNT: usize> Send for FixedBitSet<BIT_COUNT, BYTE_COUNT>
impl<const BIT_COUNT: usize, const BYTE_COUNT: usize> Sync for FixedBitSet<BIT_COUNT, BYTE_COUNT>
impl<const BIT_COUNT: usize, const BYTE_COUNT: usize> Unpin for FixedBitSet<BIT_COUNT, BYTE_COUNT>
impl<const BIT_COUNT: usize, const BYTE_COUNT: usize> UnwindSafe for FixedBitSet<BIT_COUNT, BYTE_COUNT>
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,
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Convert
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Convert
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Convert
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.§impl<T> DowncastSync for T
impl<T> DowncastSync for T
§impl<T> DynEq for T
impl<T> DynEq for T
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<T> FromWorld for Twhere
T: Default,
impl<T> FromWorld for Twhere
T: Default,
§fn from_world(_world: &mut World) -> T
fn from_world(_world: &mut World) -> T
Creates
Self using data from the given [World].