pub struct SimpleTarget {
pub tables: HashMap<String, Vec<Vec<SqliteValue>>>,
}Expand description
A simple in-memory “database” for testing changeset application.
Maps table_name -> Vec<row> where each row is Vec<SqliteValue>.
This is intentionally minimal; the real apply engine would operate on
the B-tree layer.
Fields§
§tables: HashMap<String, Vec<Vec<SqliteValue>>>Implementations§
Source§impl SimpleTarget
impl SimpleTarget
Sourcepub fn apply<F>(&mut self, changeset: &Changeset, handler: F) -> ApplyOutcome
pub fn apply<F>(&mut self, changeset: &Changeset, handler: F) -> ApplyOutcome
Apply a changeset to this target, using handler for conflict
resolution.
Trait Implementations§
Source§impl Clone for SimpleTarget
impl Clone for SimpleTarget
Source§fn clone(&self) -> SimpleTarget
fn clone(&self) -> SimpleTarget
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 SimpleTarget
impl Debug for SimpleTarget
Source§impl Default for SimpleTarget
impl Default for SimpleTarget
Source§fn default() -> SimpleTarget
fn default() -> SimpleTarget
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for SimpleTarget
impl RefUnwindSafe for SimpleTarget
impl Send for SimpleTarget
impl Sync for SimpleTarget
impl Unpin for SimpleTarget
impl UnsafeUnpin for SimpleTarget
impl UnwindSafe for SimpleTarget
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