pub struct DiffChange {
pub kind: DiffChangeKind,
pub operation: Option<DoltHashId>,
}Fields§
§kind: DiffChangeKind§operation: Option<DoltHashId>Implementations§
Source§impl DiffChange
impl DiffChange
Sourcepub const fn unchanged() -> Self
pub const fn unchanged() -> Self
Creates the neutral annotation used for graph elements shared by both endpoints.
Input builders and merge helpers use this constructor so unchanged context has neither a change kind nor misleading operation attribution.
Sourcepub const fn new(kind: DiffChangeKind, operation: Option<DoltHashId>) -> Self
pub const fn new(kind: DiffChangeKind, operation: Option<DoltHashId>) -> Self
Creates an annotation from the change kind and attribution collected from Dolt.
Input-graph construction uses this common constructor before the source and target annotations are consolidated into the rendered diff graph.
Sourcepub fn operation_or(self, default_operation: DoltHashId) -> DoltHashId
pub fn operation_or(self, default_operation: DoltHashId) -> DoltHashId
Returns explicit attribution or the comparison’s fallback operation.
Change-merging code uses this when every rendered change must be tied to an operation even if the table-diff row did not provide one.
Trait Implementations§
Source§impl Clone for DiffChange
impl Clone for DiffChange
impl Copy for DiffChange
Source§impl Debug for DiffChange
impl Debug for DiffChange
impl Eq for DiffChange
Source§impl Hash for DiffChange
impl Hash for DiffChange
Source§impl Ord for DiffChange
impl Ord for DiffChange
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more
Source§impl PartialEq for DiffChange
impl PartialEq for DiffChange
Source§impl PartialOrd for DiffChange
impl PartialOrd for DiffChange
impl StructuralPartialEq for DiffChange
Auto Trait Implementations§
impl Freeze for DiffChange
impl RefUnwindSafe for DiffChange
impl Send for DiffChange
impl Sync for DiffChange
impl Unpin for DiffChange
impl UnsafeUnpin for DiffChange
impl UnwindSafe for DiffChange
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,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
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
Compare self to
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
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