pub struct ChangesetRow {
pub op: ChangeOp,
pub old_values: Vec<ChangesetValue>,
pub new_values: Vec<ChangesetValue>,
}Expand description
A single row change recorded in a changeset.
Fields§
§op: ChangeOp§old_values: Vec<ChangesetValue>For DELETE and UPDATE: the old column values. Empty for INSERT.
new_values: Vec<ChangesetValue>For INSERT and UPDATE: the new column values. Empty for DELETE.
Implementations§
Source§impl ChangesetRow
impl ChangesetRow
Sourcepub fn encode_changeset(&self, out: &mut Vec<u8>)
pub fn encode_changeset(&self, out: &mut Vec<u8>)
Encode this row change into changeset binary format.
Sourcepub fn encode_patchset(&self, out: &mut Vec<u8>, pk_flags: &[bool])
pub fn encode_patchset(&self, out: &mut Vec<u8>, pk_flags: &[bool])
Encode this row change into patchset binary format.
For INSERT and DELETE this is identical to changeset encoding. For UPDATE the old values are omitted — only PK columns (from old values) plus new values are written.
Trait Implementations§
Source§impl Clone for ChangesetRow
impl Clone for ChangesetRow
Source§fn clone(&self) -> ChangesetRow
fn clone(&self) -> ChangesetRow
Returns a duplicate of the value. Read more
1.0.0 · 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 ChangesetRow
impl Debug for ChangesetRow
Source§impl PartialEq for ChangesetRow
impl PartialEq for ChangesetRow
impl StructuralPartialEq for ChangesetRow
Auto Trait Implementations§
impl Freeze for ChangesetRow
impl RefUnwindSafe for ChangesetRow
impl Send for ChangesetRow
impl Sync for ChangesetRow
impl Unpin for ChangesetRow
impl UnsafeUnpin for ChangesetRow
impl UnwindSafe for ChangesetRow
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