public static void CreateConstraints(this IAlterProcessor proc, IEnumerable constraints) { if (constraints == null) { return; } foreach (ConstraintInfo cnt in constraints) { proc.CreateConstraint(cnt); } }
public static void CreateConstraints(this IAlterProcessor fmt, IEnumerable constraints) { if (constraints == null) { return; } foreach (IConstraint cnt in constraints) { fmt.CreateConstraint(cnt); } }
public static void CreateObject(this IAlterProcessor proc, IAbstractObjectStructure obj) { var tbl = obj as ITableStructure; if (tbl != null) { proc.CreateTable(tbl); return; } var col = obj as IColumnStructure; if (col != null) { proc.CreateColumn(col); return; } var cnt = obj as IConstraint; if (cnt != null) { proc.CreateConstraint(cnt); return; } var spe = obj as ISpecificObjectStructure; if (spe != null) { proc.CreateSpecificObject(spe); return; } var sch = obj as ISchemaStructure; if (sch != null) { proc.CreateSchema(sch); return; } var dom = obj as IDomainStructure; if (dom != null) { proc.CreateDomain(dom); return; } }
public static void CreateObject(this IAlterProcessor proc, DatabaseObjectInfo obj) { var tbl = obj as TableInfo; if (tbl != null) { proc.CreateTable(tbl); return; } var col = obj as ColumnInfo; if (col != null) { proc.CreateColumn(col); return; } var cnt = obj as ConstraintInfo; if (cnt != null) { proc.CreateConstraint(cnt); return; } var spe = obj as SpecificObjectInfo; if (spe != null) { proc.CreateSpecificObject(spe); return; } //var sch = obj as ISchemaStructure; //if (sch != null) //{ // proc.CreateSchema(sch); // return; //} //var dom = obj as IDomainStructure; //if (dom != null) //{ // proc.CreateDomain(dom); // return; //} }