pub struct PlannedChange {
pub coll: String,
pub id: String,
pub kind: ChangeKind,
pub base: Option<Value>,
pub value: Option<Value>,
pub source_hash: String,
}Expand description
One document the merge would write, and the evidence for writing it.
base rides along so a plan can be reviewed without re-deriving it: an
operator reading a plan wants to see what the branch changed FROM, not just
what it changed to.
Fields§
§coll: String§id: String§kind: ChangeKind§base: Option<Value>§value: Option<Value>The value to write. None is a delete.
source_hash: StringThe branch write that causes this replay.
Carried through the plan so execute can point the destination node
back at what caused it. A merge that replayed anonymously could not
have the edge added later: nothing downstream would know which
destination write came from which branch write, and the answer is not
derivable from the values.
PHASE 5B: becomes a qualified crate::cause::Cause once the branch
lives in its own store and a bare hash stops being unambiguous.
Trait Implementations§
Source§impl Clone for PlannedChange
impl Clone for PlannedChange
Source§fn clone(&self) -> PlannedChange
fn clone(&self) -> PlannedChange
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 PlannedChange
impl Debug for PlannedChange
Source§impl<'de> Deserialize<'de> for PlannedChange
impl<'de> Deserialize<'de> for PlannedChange
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<PlannedChange, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<PlannedChange, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for PlannedChange
impl PartialEq for PlannedChange
Source§impl Serialize for PlannedChange
impl Serialize for PlannedChange
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl StructuralPartialEq for PlannedChange
Auto Trait Implementations§
impl Freeze for PlannedChange
impl RefUnwindSafe for PlannedChange
impl Send for PlannedChange
impl Sync for PlannedChange
impl Unpin for PlannedChange
impl UnsafeUnpin for PlannedChange
impl UnwindSafe for PlannedChange
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
impl<A, B, T> HttpServerConnExec<A, B> for Twhere
B: Body,
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