pub struct InMemoryBlockStore<V: Clone> { /* private fields */ }Expand description
A HashMap-backed BlockStore for any Clone block type.
Implementations§
Trait Implementations§
Source§impl<V: Clone + HasBlockId> BlockStore for InMemoryBlockStore<V>
impl<V: Clone + HasBlockId> BlockStore for InMemoryBlockStore<V>
Source§fn delete_block(&mut self, id: BlockId) -> Result<(), StoreError>
fn delete_block(&mut self, id: BlockId) -> Result<(), StoreError>
Delete a block by ID. Returns
StoreError::NotFound if absent.Source§fn query_blocks(&self, query: &Query) -> Result<QueryResult<&V>, StoreError>
fn query_blocks(&self, query: &Query) -> Result<QueryResult<&V>, StoreError>
Return a paged, optionally-filtered collection of blocks.
Auto Trait Implementations§
impl<V> Freeze for InMemoryBlockStore<V>
impl<V> RefUnwindSafe for InMemoryBlockStore<V>where
V: RefUnwindSafe,
impl<V> Send for InMemoryBlockStore<V>where
V: Send,
impl<V> Sync for InMemoryBlockStore<V>where
V: Sync,
impl<V> Unpin for InMemoryBlockStore<V>where
V: Unpin,
impl<V> UnsafeUnpin for InMemoryBlockStore<V>
impl<V> UnwindSafe for InMemoryBlockStore<V>where
V: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more