MCPcopy Create free account
hub / github.com/clockworklabs/SpacetimeDB / get

Method get

crates/table/src/fixed_bit_set.rs:195–199  ·  view source on GitHub ↗

Returns whether `idx` is set or not.

(&self, idx: usize)

Source from the content-addressed store, hash-verified

193
194 /// Returns whether `idx` is set or not.
195 pub fn get(&self, idx: usize) -> bool {
196 let (block_idx, pos_in_block) = Self::idx_to_pos(idx);
197 let block = self.storage()[block_idx];
198 (block & (B::ONE << pos_in_block)) != B::ZERO
199 }
200
201 /// Sets bit at position `idx` to `val`.
202 pub fn set(&mut self, idx: usize, val: bool) {

Callers 15

pointers_forMethod · 0.45
removeMethod · 0.45
next_vlr_offsetFunction · 0.45
updateFunction · 0.45
serialize_productFunction · 0.45
serialize_sumFunction · 0.45
is_row_presentMethod · 0.45
zero_sized_is_okFunction · 0.45
read_columnMethod · 0.45
validate_bsatnFunction · 0.45
insert_into_indicesMethod · 0.45

Calls 1

storageMethod · 0.80

Tested by

no test coverage detected