Package org.databene.mad4db

Examples of org.databene.mad4db.ComparisonConfig


    return out;
  }

  @Override
  protected void exportInfo(FilePrintWriter out) {
    ComparisonConfig config = context.getConfig();
    String tableExclusion = config.getTableExclusionPattern();
    String typeExclusion = getTypeExclusion(config);

    if (tableExclusion != null || typeExclusion != null) {
      HtmlReportUtil.startModule("SETTINGS", null, null, out);
      out.println("  <table>");
View Full Code Here


    assertEquals(ChangeSeverity.EXTENSION, schemaChange.getSubChange(TableCreation.class, "referee").getSeverity());
    assertEquals(ChangeSeverity.RESTRICTION, schemaChange.getSubChange(ForeignKeyConstraintCreation.class, "new_fk").getSeverity());
  }

  private SchemaChange createSchemaChange(boolean nullableFk) {
    SchemaChange schemaChange = new SchemaChange(new ComparisonConfig(null, null, null));
    DBTable refereeTable = new DBTable("referee");
    DBTable refererTable = new DBTable("referer");
    DBColumn fkColumn = new DBColumn("ref", refererTable, DBDataType.getInstance(Types.INTEGER, "int"));
    fkColumn.setNullable(nullableFk);
    refereeTable.addColumn(fkColumn);
View Full Code Here

    DBTable table = createTableWithColumns("tbl", 3);
    DBIndex index1 = new DBNonUniqueIndex("idx", true, table, "col1");
    DBIndex index2 = new DBNonUniqueIndex("idx", true, table, "col1");
    // when performing a comparison
    TableChange tableChange = new TableChange(table, null);
    new IndexComparator(new ComparisonConfig("db1", "db2", null)).compareObjects(index1, index2, tableChange);
    // then the result must be empty
    System.out.println(tableChange);
    List<StructuralChange<?>> indexChanges = tableChange.getSubChanges();
    assertEquals(0, indexChanges.size());
  }
View Full Code Here

    int criticalChangeCount = augmentations.size() + erredRestrictions.size() + failedRestrictions.size() +
      extensions.size() + deletions.size();
    int totalChangeCount = criticalChangeCount + passedRestrictions.size() + reorganizations.size() + eases.size();
    FilePrintWriter out = null;
    try {
      ComparisonConfig config = schemaChange.getConfig();
      out = createFile(context.reportFile(filename), config);

      exportInfo(out);
     
      startSummary(totalChangeCount, out);
View Full Code Here

TOP

Related Classes of org.databene.mad4db.ComparisonConfig

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.