public static Task ResetAllModificationTimes(this IDataStore ds) { return(ds.ExecuteInTransactionAsync(ctx => { foreach (var type in SqliteDataStore.DiscoverDataObjectTypes()) { var con = ctx.Connection; var tbl = con.GetMapping(type).TableName; if (type.IsSubclassOf(typeof(CommonData))) { var q = String.Concat( "UPDATE ", tbl, " SET ModifiedAt = ? ", "WHERE RemoteId IS NOT NULL AND DeletedAt IS NULL ", "AND (IsDirty = 0 OR RemoteRejected = 1)"); ctx.Connection.Execute(q, DateTime.MinValue); } } })); }
public Context(SqliteDataStore store, string dbPath) { this.store = store; conn = new SQLiteConnection(dbPath); }
public Context(SqliteDataStore store, SQLiteConnection conn) { this.store = store; this.conn = conn; Messages = new List <DataChangeMessage> (); }
public QueryBuilder(SqliteDataStore store, TableQuery <T> query) { this.store = store; this.query = query; }