pub struct Database { /* private fields */ }
Expand description
Implementations
sourceimpl Database
impl Database
sourcepub fn insert_blooms<'a, I, B>(&self, from: u64, blooms: I) -> Result<()> where
BloomRef<'a>: From<B>,
I: Iterator<Item = B>,
pub fn insert_blooms<'a, I, B>(&self, from: u64, blooms: I) -> Result<()> where
BloomRef<'a>: From<B>,
I: Iterator<Item = B>,
Inserts one or more blooms into database.
Arguments
from
- index of the first bloom that needs to be insertedblooms
- iterator over blooms
sourcepub fn filter<'a, B, I, II>(
&self,
from: u64,
to: u64,
blooms: II
) -> Result<Vec<u64>> where
BloomRef<'a>: From<B>,
II: IntoIterator<Item = B, IntoIter = I> + Copy,
I: Iterator<Item = B>,
pub fn filter<'a, B, I, II>(
&self,
from: u64,
to: u64,
blooms: II
) -> Result<Vec<u64>> where
BloomRef<'a>: From<B>,
II: IntoIterator<Item = B, IntoIter = I> + Copy,
I: Iterator<Item = B>,
Returns indexes of all headers matching given bloom in a specified range.
Arguments
from
- index of the first bloom that needs to be checkedto
- index of the last bloom that needs to be checked (inclusive range)blooms
- searched pattern
Auto Trait Implementations
impl !RefUnwindSafe for Database
impl Send for Database
impl Sync for Database
impl Unpin for Database
impl UnwindSafe for Database
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more