#[non_exhaustive]pub struct ScanOptions {
pub filter: Option<Predicate>,
pub columns: Columns,
pub batch_rows: usize,
pub after: Option<String>,
pub until: Option<String>,
pub limit: Option<u64>,
}Expand description
Settings for Namespace::scan.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.filter: Option<Predicate>Return only documents that match. Checked against the schema before any storage call.
columns: ColumnsWhat each batch carries besides ids.
batch_rows: usizeThe most rows per batch, 1 to MAX_SCAN_BATCH_ROWS. Default
DEFAULT_SCAN_BATCH_ROWS.
after: Option<String>Start after this id, in byte order. Pass the last batch’s
ScanBatch::last_id to resume a scan.
until: Option<String>Stop after this id, which is included, in byte order. With
after it bounds a range scan; an until at or below
after is an empty scan.
limit: Option<u64>Stop after this many rows in all.
Implementations§
Source§impl ScanOptions
impl ScanOptions
Sourcepub fn batch_rows(self, rows: usize) -> Self
pub fn batch_rows(self, rows: usize) -> Self
Set batch_rows.
Trait Implementations§
Source§impl Clone for ScanOptions
impl Clone for ScanOptions
Source§impl Debug for ScanOptions
impl Debug for ScanOptions
Source§impl Default for ScanOptions
impl Default for ScanOptions
Source§impl<'de> Deserialize<'de> for ScanOptionswhere
ScanOptions: Default,
impl<'de> Deserialize<'de> for ScanOptionswhere
ScanOptions: Default,
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for ScanOptions
impl PartialEq for ScanOptions
Source§impl Serialize for ScanOptions
impl Serialize for ScanOptions
impl StructuralPartialEq for ScanOptions
Auto Trait Implementations§
impl Forget for ScanOptions
impl Freeze for ScanOptionswhere
*const u8 is !null: Freeze,
PhantomData<Predicate>: Freeze,
*const Predicate is !null: Freeze,
PhantomData<u8>: Freeze,
PhantomData<f64>: Freeze,
PhantomData<String>: Freeze,
PhantomData<AttrValue>: Freeze,
impl Move for ScanOptions
impl RefUnwindSafe for ScanOptions
impl Send for ScanOptions
impl Sync for ScanOptions
impl Unpin for ScanOptions
impl UnsafeUnpin for ScanOptionswhere
*const u8 is !null: UnsafeUnpin,
PhantomData<Predicate>: UnsafeUnpin,
*const Predicate is !null: UnsafeUnpin,
PhantomData<u8>: UnsafeUnpin,
PhantomData<f64>: UnsafeUnpin,
PhantomData<String>: UnsafeUnpin,
PhantomData<AttrValue>: UnsafeUnpin,
impl UnwindSafe for ScanOptions
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,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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