pub struct OverflowChain<'p, P: PageStore> { /* private fields */ }Expand description
Chain operations over a pager.
Held by value rather than as impl Pager methods to keep overflow concerns
out of engine::pager. Slice E will hold one of these from inside the
B-tree write path.
Implementations§
Source§impl<'p, P: PageStore> OverflowChain<'p, P>
impl<'p, P: PageStore> OverflowChain<'p, P>
pub fn new(pager: &'p P) -> Self
Sourcepub fn store(&self, bytes: &[u8]) -> Result<(u32, u64), OverflowError>
pub fn store(&self, bytes: &[u8]) -> Result<(u32, u64), OverflowError>
Allocate enough overflow pages to hold bytes, link them, and return
the head page id together with the total length.
Empty input still produces a single zero-length head page so that the leaf-side pointer is always valid.
Auto Trait Implementations§
impl<'p, P> Freeze for OverflowChain<'p, P>
impl<'p, P> RefUnwindSafe for OverflowChain<'p, P>where
&'p P: RefUnwindSafe,
impl<'p, P> Send for OverflowChain<'p, P>
impl<'p, P> Sync for OverflowChain<'p, P>
impl<'p, P> Unpin for OverflowChain<'p, P>
impl<'p, P> UnsafeUnpin for OverflowChain<'p, P>where
&'p P: UnsafeUnpin,
impl<'p, P> UnwindSafe for OverflowChain<'p, P>where
&'p P: 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