pub struct RefTransaction {
pub push_seq: u64,
pub refname: String,
pub old_oid: Option<ObjectId>,
pub new_oid: Option<ObjectId>,
pub old_symref: Option<String>,
pub new_symref: Option<String>,
pub actor: String,
pub at_unix_ms: i64,
}Expand description
One row of the reference history: a single reference moving, once.
Fields§
§push_seq: u64Which frame of the source log this row came from. See COL_PUSH_SEQ.
refname: StringThe full reference name, refs/heads/main and not main.
old_oid: Option<ObjectId>The value before, absent for a creation and on a snapshot row.
new_oid: Option<ObjectId>The value after, absent for a deletion and for a symbolic target.
old_symref: Option<String>The symbolic value before, for a HEAD-shaped reference.
new_symref: Option<String>The symbolic value after.
actor: StringWho did it. COMPACTION_ACTOR means this is a snapshot row.
at_unix_ms: i64When, in milliseconds since the epoch.
Implementations§
Source§impl RefTransaction
impl RefTransaction
Sourcepub fn is_snapshot(&self) -> bool
pub fn is_snapshot(&self) -> bool
Whether this row is a compaction’s snapshot of state rather than a reference actually moving.
The test is the one COMPACTION_ACTOR documents: the actor and a
null previous value, both, since a genuine creation by a client also has
a null previous value and a client could in principle be named
gunnar:compaction.
Sourcepub fn is_deletion(&self) -> bool
pub fn is_deletion(&self) -> bool
Whether this row deletes the reference: no value after, either kind.
Trait Implementations§
Source§impl Clone for RefTransaction
impl Clone for RefTransaction
Source§impl Debug for RefTransaction
impl Debug for RefTransaction
impl Eq for RefTransaction
Source§impl PartialEq for RefTransaction
impl PartialEq for RefTransaction
impl StructuralPartialEq for RefTransaction
Auto Trait Implementations§
impl Freeze for RefTransaction
impl RefUnwindSafe for RefTransaction
impl Send for RefTransaction
impl Sync for RefTransaction
impl Unpin for RefTransaction
impl UnsafeUnpin for RefTransaction
impl UnwindSafe for RefTransaction
Blanket Implementations§
impl<T> Allocation for T
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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
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,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.