private void Commit(Action <InMemoryTransaction> action)
 {
     using (var transaction = new InMemoryTransaction(new InMemoryDispatcherBase(_state)))
     {
         action(transaction);
         transaction.Commit();
     }
 }
 public IDbTransaction BeginTransaction()
 {
     _transacton?.Rollback();
     _transacton = new InMemoryTransaction(this);
     return(_transacton);
 }