protected void GenSchemaTable(object sender, EventArgs e) { SchemaDefineCollection schemas = SchemaExtensions.CreateSchemasDefineFromConfiguration(); using (TransactionScope scope = TransactionScopeFactory.Create()) { schemas.ForEach(schema => SchemaDefineAdapter.Instance.Update(schema)); scope.Complete(); } }
public void SchemaDefinePersistTest() { SchemaDefineCollection schemas = SchemaExtensions.CreateSchemasDefineFromConfiguration(); using (TransactionScope scope = TransactionScopeFactory.Create()) { schemas.ForEach(schema => SchemaDefineAdapter.Instance.Update(schema)); scope.Complete(); } }
private void InitAllUsers() { InSqlClauseBuilder inBuilder = new InSqlClauseBuilder("SchemaType"); SchemaDefineCollection schemas = SchemaExtensions.CreateSchemasDefineFromConfiguration(); schemas.ForEach(schema => { if (string.Compare(schema.Category, "Users", true) == 0) { inBuilder.AppendItem(schema.Name); } }); this._AllUsers = SchemaObjectAdapter.Instance.Load(inBuilder); }