Struct scalable_cuckoo_filter::ScalableCuckooFilterBuilder [−][src]
Builder for ScalableCuckooFilter
.
Implementations
impl ScalableCuckooFilterBuilder<DefaultHasher, DefaultRng>
[src]
impl<H: Hasher + Clone, R: Rng> ScalableCuckooFilterBuilder<H, R>
[src]
pub fn initial_capacity(self, capacity_hint: usize) -> Self
[src]
Sets the initial capacity (i.e., the number of estimated maximum items) of this filter.
The default value is 100_000
.
pub fn false_positive_probability(self, probability: f64) -> Self
[src]
Sets the expected upper bound of the false positive probability of this filter.
The default value is 0.001
.
Panics
This method panics if probability
is not a non-negative number smaller than or equal to 1.0
.
pub fn entries_per_bucket(self, n: usize) -> Self
[src]
Sets the number of entries per bucket of this filter.
The default value is 4
.
pub fn max_kicks(self, kicks: usize) -> Self
[src]
Sets the maximum number of relocations in an insertion.
If this limit exceeded, the filter will be expanded.
The default value is 512
.
pub fn hasher<T: Hasher + Clone>(
self,
hasher: T
) -> ScalableCuckooFilterBuilder<T, R>
[src]
self,
hasher: T
) -> ScalableCuckooFilterBuilder<T, R>
Sets the hasher of this filter.
The default value if DefaultHasher::new()
.
pub fn rng<T: Rng>(self, rng: T) -> ScalableCuckooFilterBuilder<H, T>
[src]
Sets the random number generator of this filter.
The default value is rand::thread_rng()
.
pub fn finish<T: Hash + ?Sized>(self) -> ScalableCuckooFilter<T, H, R>
[src]
Builds a ScalableCuckooFilter
instance.
Trait Implementations
impl<H: Debug, R: Debug> Debug for ScalableCuckooFilterBuilder<H, R>
[src]
impl Default for ScalableCuckooFilterBuilder
[src]
Auto Trait Implementations
impl<H, R> RefUnwindSafe for ScalableCuckooFilterBuilder<H, R> where
H: RefUnwindSafe,
R: RefUnwindSafe,
H: RefUnwindSafe,
R: RefUnwindSafe,
impl<H, R> Send for ScalableCuckooFilterBuilder<H, R> where
H: Send,
R: Send,
H: Send,
R: Send,
impl<H, R> Sync for ScalableCuckooFilterBuilder<H, R> where
H: Sync,
R: Sync,
H: Sync,
R: Sync,
impl<H, R> Unpin for ScalableCuckooFilterBuilder<H, R> where
H: Unpin,
R: Unpin,
H: Unpin,
R: Unpin,
impl<H, R> UnwindSafe for ScalableCuckooFilterBuilder<H, R> where
H: UnwindSafe,
R: UnwindSafe,
H: UnwindSafe,
R: UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,