[−][src]Struct boomphf::hashmap::BoomHashMap2
A HashMap data structure where the mapping between keys and 2 values is encoded in a Mphf. You should usually use BoomHashMap with a tuple/struct value type.
If the layout overhead of the struct / tuple must be avoided, this variant of is an alternative.
This lets us store the keys and values in dense
arrays, with ~3 bits/item overhead in the Mphf.
Methods
impl<K, D1, D2> BoomHashMap2<K, D1, D2> where
K: Clone + Hash + Debug + PartialEq,
D1: Debug,
D2: Debug, [src]
impl<K, D1, D2> BoomHashMap2<K, D1, D2> where
K: Clone + Hash + Debug + PartialEq,
D1: Debug,
D2: Debug, pub fn new(
keys: Vec<K>,
values: Vec<D1>,
aux_values: Vec<D2>
) -> BoomHashMap2<K, D1, D2>[src]
pub fn new(
keys: Vec<K>,
values: Vec<D1>,
aux_values: Vec<D2>
) -> BoomHashMap2<K, D1, D2>Create a new hash map from the parallel arrays keys and values, and aux_values
pub fn get(&self, kmer: &K) -> Option<(&D1, &D2)>[src]
pub fn get(&self, kmer: &K) -> Option<(&D1, &D2)>pub fn get_key_id(&self, kmer: &K) -> Option<usize>[src]
pub fn get_key_id(&self, kmer: &K) -> Option<usize>pub fn len(&self) -> usize[src]
pub fn len(&self) -> usizeⓘImportant traits for Boom2Iterator<'a, K, D1, D2>pub fn iter(&self) -> Boom2Iterator<K, D1, D2>[src]
pub fn iter(&self) -> Boom2Iterator<K, D1, D2>pub fn get_key(&self, id: usize) -> Option<&K>[src]
pub fn get_key(&self, id: usize) -> Option<&K>impl<K, D1, D2> BoomHashMap2<K, D1, D2> where
K: Clone + Hash + Debug + PartialEq + Send + Sync,
D1: Debug,
D2: Debug, [src]
impl<K, D1, D2> BoomHashMap2<K, D1, D2> where
K: Clone + Hash + Debug + PartialEq + Send + Sync,
D1: Debug,
D2: Debug, pub fn new_parallel(
keys: Vec<K>,
data: Vec<D1>,
aux_data: Vec<D2>
) -> BoomHashMap2<K, D1, D2>[src]
pub fn new_parallel(
keys: Vec<K>,
data: Vec<D1>,
aux_data: Vec<D2>
) -> BoomHashMap2<K, D1, D2>Create a new hash map from the parallel arrays keys and values, and aux_values, using a parallel algorithm to construct the Mphf.
Trait Implementations
impl<'a, K: Hash, D1, D2> IntoIterator for &'a BoomHashMap2<K, D1, D2>[src]
impl<'a, K: Hash, D1, D2> IntoIterator for &'a BoomHashMap2<K, D1, D2>type Item = (&'a K, &'a D1, &'a D2)
The type of the elements being iterated over.
type IntoIter = Boom2Iterator<'a, K, D1, D2>
Which kind of iterator are we turning this into?
ⓘImportant traits for Boom2Iterator<'a, K, D1, D2>fn into_iter(self) -> Boom2Iterator<'a, K, D1, D2>[src]
fn into_iter(self) -> Boom2Iterator<'a, K, D1, D2>impl<K: Debug + Hash, D1: Debug, D2: Debug> Debug for BoomHashMap2<K, D1, D2>[src]
impl<K: Debug + Hash, D1: Debug, D2: Debug> Debug for BoomHashMap2<K, D1, D2>Auto Trait Implementations
impl<K, D1, D2> Send for BoomHashMap2<K, D1, D2> where
D1: Send,
D2: Send,
K: Send,
impl<K, D1, D2> Send for BoomHashMap2<K, D1, D2> where
D1: Send,
D2: Send,
K: Send, impl<K, D1, D2> Sync for BoomHashMap2<K, D1, D2> where
D1: Sync,
D2: Sync,
K: Sync,
impl<K, D1, D2> Sync for BoomHashMap2<K, D1, D2> where
D1: Sync,
D2: Sync,
K: Sync, Blanket Implementations
impl<T, U> Into for T where
U: From<T>, [src]
impl<T, U> Into for T where
U: From<T>, impl<T> From for T[src]
impl<T> From for Timpl<T, U> TryFrom for T where
T: From<U>, [src]
impl<T, U> TryFrom for T where
T: From<U>, type Error = !
try_from)The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>impl<T> Borrow for T where
T: ?Sized, [src]
impl<T> Borrow for T where
T: ?Sized, impl<T> Any for T where
T: 'static + ?Sized, [src]
impl<T> Any for T where
T: 'static + ?Sized, fn get_type_id(&self) -> TypeId[src]
fn get_type_id(&self) -> TypeIdimpl<T, U> TryInto for T where
U: TryFrom<T>, [src]
impl<T, U> TryInto for T where
U: TryFrom<T>, type Error = <U as TryFrom<T>>::Error
try_from)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>impl<T> BorrowMut for T where
T: ?Sized, [src]
impl<T> BorrowMut for T where
T: ?Sized, fn borrow_mut(&mut self) -> &mut T[src]
fn borrow_mut(&mut self) -> &mut T