pub struct NamedQueryPageStream<'a> { /* private fields */ }Expand description
Bounded multi-page continuation stream over a named query (ADR-0339).
Implementations§
Source§impl<'a> NamedQueryPageStream<'a>
impl<'a> NamedQueryPageStream<'a>
Sourcepub fn with_max_pages(self, max_pages: u32) -> Self
pub fn with_max_pages(self, max_pages: u32) -> Self
Bounds the maximum number of pages this stream will yield (clamped to 1..=MAX_STREAMED_QUERY_PAGES).
Sourcepub const fn pages_emitted(&self) -> u32
pub const fn pages_emitted(&self) -> u32
Number of pages yielded so far.
Sourcepub const fn pinned_application_head(&self) -> Option<u64>
pub const fn pinned_application_head(&self) -> Option<u64>
Pinned snapshot application_head established by the first page.
Sourcepub async fn next_page(
&mut self,
) -> Result<Option<NamedQueryResult>, ApplicationClientError>
pub async fn next_page( &mut self, ) -> Result<Option<NamedQueryResult>, ApplicationClientError>
Fetches the next bounded page in the cursor chain, or Ok(None) when complete.
Sourcepub async fn collect_pages(
self,
) -> Result<Vec<NamedQueryResult>, ApplicationClientError>
pub async fn collect_pages( self, ) -> Result<Vec<NamedQueryResult>, ApplicationClientError>
Collects all remaining pages up to the configured page bound.
Auto Trait Implementations§
impl<'a> !RefUnwindSafe for NamedQueryPageStream<'a>
impl<'a> !UnwindSafe for NamedQueryPageStream<'a>
impl<'a> Freeze for NamedQueryPageStream<'a>
impl<'a> Send for NamedQueryPageStream<'a>
impl<'a> Sync for NamedQueryPageStream<'a>
impl<'a> Unpin for NamedQueryPageStream<'a>
impl<'a> UnsafeUnpin for NamedQueryPageStream<'a>
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request§impl<L> LayerExt<L> for L
impl<L> LayerExt<L> for L
§fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
Applies the layer to a service and wraps it in [
Layered].