Struct scylla::transport::PagingState
source · pub struct PagingState(/* private fields */);
Expand description
The state of a paged query, i.e. where to resume fetching result rows upon next request.
Cheaply clonable.
Implementations§
source§impl PagingState
impl PagingState
sourcepub fn start() -> PagingState
pub fn start() -> PagingState
A start state - the state of a not-yet-started paged query.
sourcepub fn as_bytes_slice(&self) -> Option<&Arc<[u8]>>
pub fn as_bytes_slice(&self) -> Option<&Arc<[u8]>>
Returns the inner representation of PagingState. One can use this to store paging state for a longer time, and later restore it using Self::new_from_raw_bytes. In case None is returned, this signifies PagingState::start() being underneath.
sourcepub fn new_from_raw_bytes(raw_bytes: impl Into<Arc<[u8]>>) -> PagingState
pub fn new_from_raw_bytes(raw_bytes: impl Into<Arc<[u8]>>) -> PagingState
Creates PagingState from its inner representation. One can use this to restore paging state after longer time, having previously stored it using Self::as_bytes_slice.
Trait Implementations§
source§impl Clone for PagingState
impl Clone for PagingState
source§fn clone(&self) -> PagingState
fn clone(&self) -> PagingState
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for PagingState
impl Debug for PagingState
source§impl Default for PagingState
impl Default for PagingState
source§fn default() -> PagingState
fn default() -> PagingState
Returns the “default value” for a type. Read more
source§impl PartialEq for PagingState
impl PartialEq for PagingState
source§fn eq(&self, other: &PagingState) -> bool
fn eq(&self, other: &PagingState) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Eq for PagingState
impl StructuralPartialEq for PagingState
Auto Trait Implementations§
impl Freeze for PagingState
impl RefUnwindSafe for PagingState
impl Send for PagingState
impl Sync for PagingState
impl Unpin for PagingState
impl UnwindSafe for PagingState
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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