pub struct VlenStringReadOptions { /* private fields */ }Expand description
Allocation limits for reading variable-length strings.
Limits are checked before any string payload is materialized. The payload
byte limit covers the bytes referenced by the VL elements; it excludes the
Vec<String> and String allocation metadata.
Implementations§
Source§impl VlenStringReadOptions
impl VlenStringReadOptions
Sourcepub const fn with_max_elements(self, max_elements: usize) -> Self
pub const fn with_max_elements(self, max_elements: usize) -> Self
Set the maximum number of VL elements that may be read.
Sourcepub const fn with_max_payload_bytes(self, max_payload_bytes: usize) -> Self
pub const fn with_max_payload_bytes(self, max_payload_bytes: usize) -> Self
Set the maximum total string payload size in bytes.
Sourcepub const fn max_elements(&self) -> Option<usize>
pub const fn max_elements(&self) -> Option<usize>
Return the configured element limit.
Sourcepub const fn max_payload_bytes(&self) -> Option<usize>
pub const fn max_payload_bytes(&self) -> Option<usize>
Return the configured payload-byte limit.
Trait Implementations§
Source§impl Clone for VlenStringReadOptions
impl Clone for VlenStringReadOptions
Source§fn clone(&self) -> VlenStringReadOptions
fn clone(&self) -> VlenStringReadOptions
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for VlenStringReadOptions
Source§impl Debug for VlenStringReadOptions
impl Debug for VlenStringReadOptions
Source§impl Default for VlenStringReadOptions
impl Default for VlenStringReadOptions
Source§fn default() -> VlenStringReadOptions
fn default() -> VlenStringReadOptions
Returns the “default value” for a type. Read more
impl Eq for VlenStringReadOptions
Source§impl PartialEq for VlenStringReadOptions
impl PartialEq for VlenStringReadOptions
Source§fn eq(&self, other: &VlenStringReadOptions) -> bool
fn eq(&self, other: &VlenStringReadOptions) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for VlenStringReadOptions
Auto Trait Implementations§
impl Freeze for VlenStringReadOptions
impl RefUnwindSafe for VlenStringReadOptions
impl Send for VlenStringReadOptions
impl Sync for VlenStringReadOptions
impl Unpin for VlenStringReadOptions
impl UnsafeUnpin for VlenStringReadOptions
impl UnwindSafe for VlenStringReadOptions
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