pub struct SelectionBuffers<const WANTS: usize, const OBJECTS: usize, const READ: usize, const PARSE: usize> { /* private fields */ }Expand description
Fixed-capacity backing storage for one independent selected-fetch session.
All capacities are explicit const parameters; construction allocates nothing.
Keep separate values for overlapping responses. Only the borrowed descriptor
reaches the protocol encoder, so applications may also keep their own arrays
and construct SelectionStorage directly.
Implementations§
Source§impl<const WANTS: usize, const OBJECTS: usize, const READ: usize, const PARSE: usize> SelectionBuffers<WANTS, OBJECTS, READ, PARSE>
impl<const WANTS: usize, const OBJECTS: usize, const READ: usize, const PARSE: usize> SelectionBuffers<WANTS, OBJECTS, READ, PARSE>
pub const fn new() -> Self
Sourcepub fn storage(&mut self, graph_read_limit: u64) -> SelectionStorage<'_>
pub fn storage(&mut self, graph_read_limit: u64) -> SelectionStorage<'_>
Borrow a fresh request descriptor. Traversal resets the work arrays; no clearing or reallocation is needed between successful/failed requests.
pub const fn want_capacity(&self) -> usize
pub const fn object_capacity(&self) -> usize
pub const fn read_capacity(&self) -> usize
pub const fn parse_capacity(&self) -> usize
Sourcepub const fn storage_bytes(&self) -> usize
pub const fn storage_bytes(&self) -> usize
Bytes owned by this value, including metadata and alignment padding.
Trait Implementations§
Auto Trait Implementations§
impl<const WANTS: usize, const OBJECTS: usize, const READ: usize, const PARSE: usize> Freeze for SelectionBuffers<WANTS, OBJECTS, READ, PARSE>
impl<const WANTS: usize, const OBJECTS: usize, const READ: usize, const PARSE: usize> RefUnwindSafe for SelectionBuffers<WANTS, OBJECTS, READ, PARSE>where
[ObjectId; WANTS]: RefUnwindSafe,
[Option<ValidationMetadata>; OBJECTS]: RefUnwindSafe,
[usize; OBJECTS]: RefUnwindSafe,
[u8; READ]: RefUnwindSafe,
[u8; PARSE]: RefUnwindSafe,
impl<const WANTS: usize, const OBJECTS: usize, const READ: usize, const PARSE: usize> Send for SelectionBuffers<WANTS, OBJECTS, READ, PARSE>
impl<const WANTS: usize, const OBJECTS: usize, const READ: usize, const PARSE: usize> Sync for SelectionBuffers<WANTS, OBJECTS, READ, PARSE>
impl<const WANTS: usize, const OBJECTS: usize, const READ: usize, const PARSE: usize> Unpin for SelectionBuffers<WANTS, OBJECTS, READ, PARSE>
impl<const WANTS: usize, const OBJECTS: usize, const READ: usize, const PARSE: usize> UnsafeUnpin for SelectionBuffers<WANTS, OBJECTS, READ, PARSE>where
[ObjectId; WANTS]: UnsafeUnpin,
[Option<ValidationMetadata>; OBJECTS]: UnsafeUnpin,
[usize; OBJECTS]: UnsafeUnpin,
[u8; READ]: UnsafeUnpin,
[u8; PARSE]: UnsafeUnpin,
impl<const WANTS: usize, const OBJECTS: usize, const READ: usize, const PARSE: usize> UnwindSafe for SelectionBuffers<WANTS, OBJECTS, READ, PARSE>where
[ObjectId; WANTS]: UnwindSafe,
[Option<ValidationMetadata>; OBJECTS]: UnwindSafe,
[usize; OBJECTS]: UnwindSafe,
[u8; READ]: UnwindSafe,
[u8; PARSE]: 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