pub struct RowVersion {
pub id: u64,
pub row: Row,
pub btree_resident: bool,
/* private fields */
}Expand description
A row version.
Fields§
§id: u64Unique identifier for this version within the MvStore. Used for savepoint tracking to identify specific versions to rollback.
row: Row§btree_resident: boolIndicates this version was created for a row that existed in B-tree before MVCC was enabled (e.g., after switching from WAL to MVCC journal mode). This flag helps the checkpoint logic determine if a delete should be checkpointed to the B-tree file.
Implementations§
Source§impl RowVersion
impl RowVersion
Sourcepub fn new(
id: u64,
begin: Option<TxTimestampOrID>,
end: Option<TxTimestampOrID>,
row: Row,
btree_resident: bool,
) -> Self
pub fn new( id: u64, begin: Option<TxTimestampOrID>, end: Option<TxTimestampOrID>, row: Row, btree_resident: bool, ) -> Self
Construct a row version. begin/end are bit-packed internally.
Sourcepub fn begin(&self) -> Option<TxTimestampOrID>
pub fn begin(&self) -> Option<TxTimestampOrID>
The begin timestamp/tx-id, or None.
Sourcepub fn end(&self) -> Option<TxTimestampOrID>
pub fn end(&self) -> Option<TxTimestampOrID>
The end timestamp/tx-id, or None.
pub fn set_begin(&mut self, value: Option<TxTimestampOrID>)
pub fn set_end(&mut self, value: Option<TxTimestampOrID>)
Trait Implementations§
Source§impl Clone for RowVersion
impl Clone for RowVersion
Source§fn clone(&self) -> RowVersion
fn clone(&self) -> RowVersion
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 moreSource§impl Debug for RowVersion
impl Debug for RowVersion
Source§impl PartialEq for RowVersion
impl PartialEq for RowVersion
impl StructuralPartialEq for RowVersion
Auto Trait Implementations§
impl Freeze for RowVersion
impl RefUnwindSafe for RowVersion
impl Send for RowVersion
impl Sync for RowVersion
impl Unpin for RowVersion
impl UnsafeUnpin for RowVersion
impl UnwindSafe for RowVersion
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> ErasedDestructor for Twhere
T: 'static,
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