pub struct AsyncSecondaryIndexSnapshot<'a, S: AsyncIndexedStore> { /* private fields */ }Expand description
One immutable secondary-index tree selected by an async snapshot.
Implementations§
Source§impl<'a, S> AsyncSecondaryIndexSnapshot<'a, S>where
S: AsyncIndexedStore + Clone,
<S as AsyncStore>::Error: Send + Sync,
<S as AsyncManifestStore>::Error: Send + Sync,
impl<'a, S> AsyncSecondaryIndexSnapshot<'a, S>where
S: AsyncIndexedStore + Clone,
<S as AsyncStore>::Error: Send + Sync,
<S as AsyncManifestStore>::Error: Send + Sync,
Sourcepub fn query(
&self,
budget: QueryBudget,
) -> Result<AsyncSecondaryIndexQuery<'_, 'a, S>, Error>
pub fn query( &self, budget: QueryBudget, ) -> Result<AsyncSecondaryIndexQuery<'_, 'a, S>, Error>
Create a finite-budget query session.
pub fn name(&self) -> &[u8] ⓘ
pub fn descriptor(&self) -> &IndexDescriptor
pub fn snapshot_ref(&self) -> &IndexSnapshotRef
pub fn tree(&self) -> &Tree
pub async fn exact( &self, term: &[u8], ) -> Result<Vec<SecondaryIndexMatch>, Error>
pub async fn prefix( &self, prefix: &[u8], ) -> Result<Vec<SecondaryIndexMatch>, Error>
pub async fn range( &self, start_term: &[u8], end_term: Option<&[u8]>, ) -> Result<Vec<SecondaryIndexMatch>, Error>
pub async fn primary_keys(&self, term: &[u8]) -> Result<Vec<Vec<u8>>, Error>
pub async fn projected( &self, term: &[u8], ) -> Result<Vec<ProjectedIndexEntry>, Error>
Sourcepub async fn records(
&self,
term: &[u8],
) -> Result<Vec<IndexedSourceRecord>, Error>
pub async fn records( &self, term: &[u8], ) -> Result<Vec<IndexedSourceRecord>, Error>
Resolve matching primary keys with one native ordered async batch read.
pub async fn scan_exact( &self, term: &[u8], visit: impl for<'row> FnMut(SecondaryIndexMatchRef<'row>), ) -> Result<u64, Error>
pub async fn scan_exact_until<B>( &self, term: &[u8], visit: impl for<'row> FnMut(SecondaryIndexMatchRef<'row>) -> ControlFlow<B>, ) -> Result<ScanOutcome<B>, Error>
pub async fn scan_prefix( &self, prefix: &[u8], visit: impl for<'row> FnMut(SecondaryIndexMatchRef<'row>), ) -> Result<u64, Error>
pub async fn scan_prefix_until<B>( &self, prefix: &[u8], visit: impl for<'row> FnMut(SecondaryIndexMatchRef<'row>) -> ControlFlow<B>, ) -> Result<ScanOutcome<B>, Error>
pub async fn scan_range( &self, start: &[u8], end: Option<&[u8]>, visit: impl for<'row> FnMut(SecondaryIndexMatchRef<'row>), ) -> Result<u64, Error>
pub async fn scan_range_until<B>( &self, start: &[u8], end: Option<&[u8]>, visit: impl for<'row> FnMut(SecondaryIndexMatchRef<'row>) -> ControlFlow<B>, ) -> Result<ScanOutcome<B>, Error>
pub async fn scan_exact_reverse( &self, term: &[u8], visit: impl for<'row> FnMut(SecondaryIndexMatchRef<'row>), ) -> Result<u64, Error>
pub async fn scan_exact_reverse_until<B>( &self, term: &[u8], visit: impl for<'row> FnMut(SecondaryIndexMatchRef<'row>) -> ControlFlow<B>, ) -> Result<ScanOutcome<B>, Error>
pub async fn scan_prefix_reverse( &self, prefix: &[u8], visit: impl for<'row> FnMut(SecondaryIndexMatchRef<'row>), ) -> Result<u64, Error>
pub async fn scan_prefix_reverse_until<B>( &self, prefix: &[u8], visit: impl for<'row> FnMut(SecondaryIndexMatchRef<'row>) -> ControlFlow<B>, ) -> Result<ScanOutcome<B>, Error>
pub async fn scan_range_reverse( &self, start: &[u8], end: Option<&[u8]>, visit: impl for<'row> FnMut(SecondaryIndexMatchRef<'row>), ) -> Result<u64, Error>
pub async fn scan_range_reverse_until<B>( &self, start: &[u8], end: Option<&[u8]>, visit: impl for<'row> FnMut(SecondaryIndexMatchRef<'row>) -> ControlFlow<B>, ) -> Result<ScanOutcome<B>, Error>
pub async fn exact_page( &self, term: &[u8], cursor: Option<&SecondaryIndexCursor>, limit: usize, ) -> Result<SecondaryIndexPage, Error>
pub async fn exact_reverse_page( &self, term: &[u8], cursor: Option<&SecondaryIndexCursor>, limit: usize, ) -> Result<SecondaryIndexPage, Error>
pub async fn prefix_page( &self, prefix: &[u8], cursor: Option<&SecondaryIndexCursor>, limit: usize, ) -> Result<SecondaryIndexPage, Error>
pub async fn prefix_reverse_page( &self, prefix: &[u8], cursor: Option<&SecondaryIndexCursor>, limit: usize, ) -> Result<SecondaryIndexPage, Error>
pub async fn range_page( &self, start: &[u8], end: Option<&[u8]>, cursor: Option<&SecondaryIndexCursor>, limit: usize, ) -> Result<SecondaryIndexPage, Error>
pub async fn range_reverse_page( &self, start: &[u8], end: Option<&[u8]>, cursor: Option<&SecondaryIndexCursor>, limit: usize, ) -> Result<SecondaryIndexPage, Error>
Sourcepub fn exact_cursor_after(
&self,
query_term: &[u8],
term: &[u8],
primary_key: &[u8],
direction: SecondaryIndexDirection,
) -> Result<SecondaryIndexCursor, Error>
pub fn exact_cursor_after( &self, query_term: &[u8], term: &[u8], primary_key: &[u8], direction: SecondaryIndexDirection, ) -> Result<SecondaryIndexCursor, Error>
Construct a snapshot-bound continuation cursor from the logical term
and primary key carried by a DynamoDB-style ExclusiveStartKey.
pub fn prefix_cursor_after( &self, query_prefix: &[u8], term: &[u8], primary_key: &[u8], direction: SecondaryIndexDirection, ) -> Result<SecondaryIndexCursor, Error>
pub fn range_cursor_after( &self, start: &[u8], end: Option<&[u8]>, term: &[u8], primary_key: &[u8], direction: SecondaryIndexDirection, ) -> Result<SecondaryIndexCursor, Error>
Auto Trait Implementations§
impl<'a, S> Freeze for AsyncSecondaryIndexSnapshot<'a, S>where
&'a ProllyEngine<S>: Freeze,
impl<'a, S> RefUnwindSafe for AsyncSecondaryIndexSnapshot<'a, S>where
&'a ProllyEngine<S>: RefUnwindSafe,
impl<'a, S> Send for AsyncSecondaryIndexSnapshot<'a, S>where
&'a ProllyEngine<S>: Send,
impl<'a, S> Sync for AsyncSecondaryIndexSnapshot<'a, S>where
&'a ProllyEngine<S>: Sync,
impl<'a, S> Unpin for AsyncSecondaryIndexSnapshot<'a, S>where
&'a ProllyEngine<S>: Unpin,
impl<'a, S> UnsafeUnpin for AsyncSecondaryIndexSnapshot<'a, S>where
&'a ProllyEngine<S>: UnsafeUnpin,
impl<'a, S> UnwindSafe for AsyncSecondaryIndexSnapshot<'a, S>where
&'a ProllyEngine<S>: 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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more