pub trait IteratableFilterStore: Send + Sync + IntoIterator<Item = (u32, BlockFilter)> {
    type I: Iterator<Item = (u32, BlockFilter)>;

    // Required methods
    fn iter(
        &self,
        start_height: Option<usize>
    ) -> Result<Self::I, IteratableFilterStoreError>;
    fn put_filter(
        &self,
        block_filter: BlockFilter,
        height: u32
    ) -> Result<(), IteratableFilterStoreError>;
    fn set_height(&self, height: u32) -> Result<(), IteratableFilterStoreError>;
    fn get_height(&self) -> Result<u32, IteratableFilterStoreError>;
}

Required Associated Types§

source

type I: Iterator<Item = (u32, BlockFilter)>

Required Methods§

source

fn iter( &self, start_height: Option<usize> ) -> Result<Self::I, IteratableFilterStoreError>

Fetches the first filter and sets our internal cursor to the first filter, succeeding calls to [next] will return the next filter until we reach the end

source

fn put_filter( &self, block_filter: BlockFilter, height: u32 ) -> Result<(), IteratableFilterStoreError>

Writes a new filter to the store

source

fn set_height(&self, height: u32) -> Result<(), IteratableFilterStoreError>

Persists the height of the last filter we have

source

fn get_height(&self) -> Result<u32, IteratableFilterStoreError>

Fetches the height of the last filter we have

Implementors§