[][src]Trait sized_chunks::types::Bits

pub trait Bits: Unsigned {
    type Store: Default + Copy + PartialEq + Debug;
    fn get(bits: &Self::Store, index: usize) -> bool;
fn set(bits: &mut Self::Store, index: usize, value: bool) -> bool;
fn len(bits: &Self::Store) -> usize;
fn first_index(bits: &Self::Store) -> Option<usize>; }

A type level number signifying the number of bits in a bitmap.

This trait is implemented for type level numbers from U1 to U128.

Examples

assert_eq!(
    std::mem::size_of::<<U10 as Bits>::Store>(),
    std::mem::size_of::<u16>()
);

Associated Types

type Store: Default + Copy + PartialEq + Debug

A primitive integer type suitable for storing this many bits.

Loading content...

Required methods

fn get(bits: &Self::Store, index: usize) -> bool

fn set(bits: &mut Self::Store, index: usize, value: bool) -> bool

fn len(bits: &Self::Store) -> usize

fn first_index(bits: &Self::Store) -> Option<usize>

Loading content...

Implementations on Foreign Types

impl Bits for U1[src]

type Store = u8

impl Bits for U2[src]

type Store = u8

impl Bits for U3[src]

type Store = u8

impl Bits for U4[src]

type Store = u8

impl Bits for U5[src]

type Store = u8

impl Bits for U6[src]

type Store = u8

impl Bits for U7[src]

type Store = u8

impl Bits for U8[src]

type Store = u8

impl Bits for U9[src]

type Store = u16

impl Bits for U10[src]

type Store = u16

impl Bits for U11[src]

type Store = u16

impl Bits for U12[src]

type Store = u16

impl Bits for U13[src]

type Store = u16

impl Bits for U14[src]

type Store = u16

impl Bits for U15[src]

type Store = u16

impl Bits for U16[src]

type Store = u16

impl Bits for U17[src]

type Store = u32

impl Bits for U18[src]

type Store = u32

impl Bits for U19[src]

type Store = u32

impl Bits for U20[src]

type Store = u32

impl Bits for U21[src]

type Store = u32

impl Bits for U22[src]

type Store = u32

impl Bits for U23[src]

type Store = u32

impl Bits for U24[src]

type Store = u32

impl Bits for U25[src]

type Store = u32

impl Bits for U26[src]

type Store = u32

impl Bits for U27[src]

type Store = u32

impl Bits for U28[src]

type Store = u32

impl Bits for U29[src]

type Store = u32

impl Bits for U30[src]

type Store = u32

impl Bits for U31[src]

type Store = u32

impl Bits for U32[src]

type Store = u32

impl Bits for U33[src]

type Store = u64

impl Bits for U34[src]

type Store = u64

impl Bits for U35[src]

type Store = u64

impl Bits for U36[src]

type Store = u64

impl Bits for U37[src]

type Store = u64

impl Bits for U38[src]

type Store = u64

impl Bits for U39[src]

type Store = u64

impl Bits for U40[src]

type Store = u64

impl Bits for U41[src]

type Store = u64

impl Bits for U42[src]

type Store = u64

impl Bits for U43[src]

type Store = u64

impl Bits for U44[src]

type Store = u64

impl Bits for U45[src]

type Store = u64

impl Bits for U46[src]

type Store = u64

impl Bits for U47[src]

type Store = u64

impl Bits for U48[src]

type Store = u64

impl Bits for U49[src]

type Store = u64

impl Bits for U50[src]

type Store = u64

impl Bits for U51[src]

type Store = u64

impl Bits for U52[src]

type Store = u64

impl Bits for U53[src]

type Store = u64

impl Bits for U54[src]

type Store = u64

impl Bits for U55[src]

type Store = u64

impl Bits for U56[src]

type Store = u64

impl Bits for U57[src]

type Store = u64

impl Bits for U58[src]

type Store = u64

impl Bits for U59[src]

type Store = u64

impl Bits for U60[src]

type Store = u64

impl Bits for U61[src]

type Store = u64

impl Bits for U62[src]

type Store = u64

impl Bits for U63[src]

type Store = u64

impl Bits for U64[src]

type Store = u64

impl Bits for U65[src]

type Store = u128

impl Bits for U66[src]

type Store = u128

impl Bits for U67[src]

type Store = u128

impl Bits for U68[src]

type Store = u128

impl Bits for U69[src]

type Store = u128

impl Bits for U70[src]

type Store = u128

impl Bits for U71[src]

type Store = u128

impl Bits for U72[src]

type Store = u128

impl Bits for U73[src]

type Store = u128

impl Bits for U74[src]

type Store = u128

impl Bits for U75[src]

type Store = u128

impl Bits for U76[src]

type Store = u128

impl Bits for U77[src]

type Store = u128

impl Bits for U78[src]

type Store = u128

impl Bits for U79[src]

type Store = u128

impl Bits for U80[src]

type Store = u128

impl Bits for U81[src]

type Store = u128

impl Bits for U82[src]

type Store = u128

impl Bits for U83[src]

type Store = u128

impl Bits for U84[src]

type Store = u128

impl Bits for U85[src]

type Store = u128

impl Bits for U86[src]

type Store = u128

impl Bits for U87[src]

type Store = u128

impl Bits for U88[src]

type Store = u128

impl Bits for U89[src]

type Store = u128

impl Bits for U90[src]

type Store = u128

impl Bits for U91[src]

type Store = u128

impl Bits for U92[src]

type Store = u128

impl Bits for U93[src]

type Store = u128

impl Bits for U94[src]

type Store = u128

impl Bits for U95[src]

type Store = u128

impl Bits for U96[src]

type Store = u128

impl Bits for U97[src]

type Store = u128

impl Bits for U98[src]

type Store = u128

impl Bits for U99[src]

type Store = u128

impl Bits for U100[src]

type Store = u128

impl Bits for U101[src]

type Store = u128

impl Bits for U102[src]

type Store = u128

impl Bits for U103[src]

type Store = u128

impl Bits for U104[src]

type Store = u128

impl Bits for U105[src]

type Store = u128

impl Bits for U106[src]

type Store = u128

impl Bits for U107[src]

type Store = u128

impl Bits for U108[src]

type Store = u128

impl Bits for U109[src]

type Store = u128

impl Bits for U110[src]

type Store = u128

impl Bits for U111[src]

type Store = u128

impl Bits for U112[src]

type Store = u128

impl Bits for U113[src]

type Store = u128

impl Bits for U114[src]

type Store = u128

impl Bits for U115[src]

type Store = u128

impl Bits for U116[src]

type Store = u128

impl Bits for U117[src]

type Store = u128

impl Bits for U118[src]

type Store = u128

impl Bits for U119[src]

type Store = u128

impl Bits for U120[src]

type Store = u128

impl Bits for U121[src]

type Store = u128

impl Bits for U122[src]

type Store = u128

impl Bits for U123[src]

type Store = u128

impl Bits for U124[src]

type Store = u128

impl Bits for U125[src]

type Store = u128

impl Bits for U126[src]

type Store = u128

impl Bits for U127[src]

type Store = u128

impl Bits for U128[src]

type Store = u128

impl Bits for U129[src]

type Store = [u128; 2]

impl Bits for U130[src]

type Store = [u128; 2]

impl Bits for U131[src]

type Store = [u128; 2]

impl Bits for U132[src]

type Store = [u128; 2]

impl Bits for U133[src]

type Store = [u128; 2]

impl Bits for U134[src]

type Store = [u128; 2]

impl Bits for U135[src]

type Store = [u128; 2]

impl Bits for U136[src]

type Store = [u128; 2]

impl Bits for U137[src]

type Store = [u128; 2]

impl Bits for U138[src]

type Store = [u128; 2]

impl Bits for U139[src]

type Store = [u128; 2]

impl Bits for U140[src]

type Store = [u128; 2]

impl Bits for U141[src]

type Store = [u128; 2]

impl Bits for U142[src]

type Store = [u128; 2]

impl Bits for U143[src]

type Store = [u128; 2]

impl Bits for U144[src]

type Store = [u128; 2]

impl Bits for U145[src]

type Store = [u128; 2]

impl Bits for U146[src]

type Store = [u128; 2]

impl Bits for U147[src]

type Store = [u128; 2]

impl Bits for U148[src]

type Store = [u128; 2]

impl Bits for U149[src]

type Store = [u128; 2]

impl Bits for U150[src]

type Store = [u128; 2]

impl Bits for U151[src]

type Store = [u128; 2]

impl Bits for U152[src]

type Store = [u128; 2]

impl Bits for U153[src]

type Store = [u128; 2]

impl Bits for U154[src]

type Store = [u128; 2]

impl Bits for U155[src]

type Store = [u128; 2]

impl Bits for U156[src]

type Store = [u128; 2]

impl Bits for U157[src]

type Store = [u128; 2]

impl Bits for U158[src]

type Store = [u128; 2]

impl Bits for U159[src]

type Store = [u128; 2]

impl Bits for U160[src]

type Store = [u128; 2]

impl Bits for U161[src]

type Store = [u128; 2]

impl Bits for U162[src]

type Store = [u128; 2]

impl Bits for U163[src]

type Store = [u128; 2]

impl Bits for U164[src]

type Store = [u128; 2]

impl Bits for U165[src]

type Store = [u128; 2]

impl Bits for U166[src]

type Store = [u128; 2]

impl Bits for U167[src]

type Store = [u128; 2]

impl Bits for U168[src]

type Store = [u128; 2]

impl Bits for U169[src]

type Store = [u128; 2]

impl Bits for U170[src]

type Store = [u128; 2]

impl Bits for U171[src]

type Store = [u128; 2]

impl Bits for U172[src]

type Store = [u128; 2]

impl Bits for U173[src]

type Store = [u128; 2]

impl Bits for U174[src]

type Store = [u128; 2]

impl Bits for U175[src]

type Store = [u128; 2]

impl Bits for U176[src]

type Store = [u128; 2]

impl Bits for U177[src]

type Store = [u128; 2]

impl Bits for U178[src]

type Store = [u128; 2]

impl Bits for U179[src]

type Store = [u128; 2]

impl Bits for U180[src]

type Store = [u128; 2]

impl Bits for U181[src]

type Store = [u128; 2]

impl Bits for U182[src]

type Store = [u128; 2]

impl Bits for U183[src]

type Store = [u128; 2]

impl Bits for U184[src]

type Store = [u128; 2]

impl Bits for U185[src]

type Store = [u128; 2]

impl Bits for U186[src]

type Store = [u128; 2]

impl Bits for U187[src]

type Store = [u128; 2]

impl Bits for U188[src]

type Store = [u128; 2]

impl Bits for U189[src]

type Store = [u128; 2]

impl Bits for U190[src]

type Store = [u128; 2]

impl Bits for U191[src]

type Store = [u128; 2]

impl Bits for U192[src]

type Store = [u128; 2]

impl Bits for U193[src]

type Store = [u128; 2]

impl Bits for U194[src]

type Store = [u128; 2]

impl Bits for U195[src]

type Store = [u128; 2]

impl Bits for U196[src]

type Store = [u128; 2]

impl Bits for U197[src]

type Store = [u128; 2]

impl Bits for U198[src]

type Store = [u128; 2]

impl Bits for U199[src]

type Store = [u128; 2]

impl Bits for U200[src]

type Store = [u128; 2]

impl Bits for U201[src]

type Store = [u128; 2]

impl Bits for U202[src]

type Store = [u128; 2]

impl Bits for U203[src]

type Store = [u128; 2]

impl Bits for U204[src]

type Store = [u128; 2]

impl Bits for U205[src]

type Store = [u128; 2]

impl Bits for U206[src]

type Store = [u128; 2]

impl Bits for U207[src]

type Store = [u128; 2]

impl Bits for U208[src]

type Store = [u128; 2]

impl Bits for U209[src]

type Store = [u128; 2]

impl Bits for U210[src]

type Store = [u128; 2]

impl Bits for U211[src]

type Store = [u128; 2]

impl Bits for U212[src]

type Store = [u128; 2]

impl Bits for U213[src]

type Store = [u128; 2]

impl Bits for U214[src]

type Store = [u128; 2]

impl Bits for U215[src]

type Store = [u128; 2]

impl Bits for U216[src]

type Store = [u128; 2]

impl Bits for U217[src]

type Store = [u128; 2]

impl Bits for U218[src]

type Store = [u128; 2]

impl Bits for U219[src]

type Store = [u128; 2]

impl Bits for U220[src]

type Store = [u128; 2]

impl Bits for U221[src]

type Store = [u128; 2]

impl Bits for U222[src]

type Store = [u128; 2]

impl Bits for U223[src]

type Store = [u128; 2]

impl Bits for U224[src]

type Store = [u128; 2]

impl Bits for U225[src]

type Store = [u128; 2]

impl Bits for U226[src]

type Store = [u128; 2]

impl Bits for U227[src]

type Store = [u128; 2]

impl Bits for U228[src]

type Store = [u128; 2]

impl Bits for U229[src]

type Store = [u128; 2]

impl Bits for U230[src]

type Store = [u128; 2]

impl Bits for U231[src]

type Store = [u128; 2]

impl Bits for U232[src]

type Store = [u128; 2]

impl Bits for U233[src]

type Store = [u128; 2]

impl Bits for U234[src]

type Store = [u128; 2]

impl Bits for U235[src]

type Store = [u128; 2]

impl Bits for U236[src]

type Store = [u128; 2]

impl Bits for U237[src]

type Store = [u128; 2]

impl Bits for U238[src]

type Store = [u128; 2]

impl Bits for U239[src]

type Store = [u128; 2]

impl Bits for U240[src]

type Store = [u128; 2]

impl Bits for U241[src]

type Store = [u128; 2]

impl Bits for U242[src]

type Store = [u128; 2]

impl Bits for U243[src]

type Store = [u128; 2]

impl Bits for U244[src]

type Store = [u128; 2]

impl Bits for U245[src]

type Store = [u128; 2]

impl Bits for U246[src]

type Store = [u128; 2]

impl Bits for U247[src]

type Store = [u128; 2]

impl Bits for U248[src]

type Store = [u128; 2]

impl Bits for U249[src]

type Store = [u128; 2]

impl Bits for U250[src]

type Store = [u128; 2]

impl Bits for U251[src]

type Store = [u128; 2]

impl Bits for U252[src]

type Store = [u128; 2]

impl Bits for U253[src]

type Store = [u128; 2]

impl Bits for U254[src]

type Store = [u128; 2]

impl Bits for U255[src]

type Store = [u128; 2]

impl Bits for U256[src]

type Store = [u128; 2]

Loading content...

Implementors

Loading content...