[−][src]Trait sharded::Collection
Basic methods needing implemented for shard construction
Required methods
fn with_capacity(capacity: usize) -> Self
Creates an empty collection with specified capacity. Usually this means the collection should avoid resizing until that threshold is reached
fn insert(&mut self, v: Value) -> Option<Value>
Insert a (possibly) key value pair into the collection
fn get(&self, k: &K) -> Option<Value>
fn len(&self) -> usize
Returns the count of values stored in the collection
fn capacity(&self) -> usize
Returns the current specified capacity
Implementations on Foreign Types
impl<K, V, S> Collection<K, (K, V)> for HashMap<K, V, S> where
K: Hash + Clone + Eq,
V: Clone,
S: BuildHasher + Clone + Default,
[src]
K: Hash + Clone + Eq,
V: Clone,
S: BuildHasher + Clone + Default,
fn with_capacity(capacity: usize) -> Self
[src]
fn insert(&mut self, v: (K, V)) -> Option<(K, V)>
[src]
fn get(&self, _k: &K) -> Option<(K, V)>
[src]
fn len(&self) -> usize
[src]
fn capacity(&self) -> usize
[src]
impl<K, S> Collection<K, K> for HashSet<K, S> where
K: Hash + Clone + Eq,
S: BuildHasher + Clone + Default,
[src]
K: Hash + Clone + Eq,
S: BuildHasher + Clone + Default,