Search in sources :

Example 11 with TableContainer

use of org.obeonetwork.dsl.database.TableContainer in project InformationSystem by ObeoNetwork.

the class TableChangeBuilder method handleAddChange.

@Override
protected Diff handleAddChange(ReferenceChange change) {
    Comparison comparison = change.getMatch().getComparison();
    TableContainer tableContainer = (TableContainer) change.getMatch().getRight();
    Table table = (Table) change.getValue();
    return createAddTable(comparison, tableContainer, table, change);
}
Also used : AlterTable(org.obeonetwork.dsl.database.dbevolution.AlterTable) RemoveTable(org.obeonetwork.dsl.database.dbevolution.RemoveTable) Table(org.obeonetwork.dsl.database.Table) AddTable(org.obeonetwork.dsl.database.dbevolution.AddTable) Comparison(org.eclipse.emf.compare.Comparison) TableContainer(org.obeonetwork.dsl.database.TableContainer)

Example 12 with TableContainer

use of org.obeonetwork.dsl.database.TableContainer in project InformationSystem by ObeoNetwork.

the class AbstractSQLGenerationTest method assertGenerationEquals.

public void assertGenerationEquals(String inputFolderName) {
    TableContainer source = loadTableContainerFromFile(inputFolderName, INPUT_FILENAME_1);
    TableContainer target = loadTableContainerFromFile(inputFolderName, INPUT_FILENAME_2);
    assertGenerationEquals(source, target, INPUT + inputFolderName + "/expectedSql");
}
Also used : TableContainer(org.obeonetwork.dsl.database.TableContainer)

Aggregations

TableContainer (org.obeonetwork.dsl.database.TableContainer)12 Comparison (org.eclipse.emf.compare.Comparison)4 EObject (org.eclipse.emf.ecore.EObject)4 Resource (org.eclipse.emf.ecore.resource.Resource)3 ResourceSet (org.eclipse.emf.ecore.resource.ResourceSet)3 Table (org.obeonetwork.dsl.database.Table)3 Namespace (org.obeonetwork.dsl.environment.Namespace)3 ResourceSetImpl (org.eclipse.emf.ecore.resource.impl.ResourceSetImpl)2 DataBase (org.obeonetwork.dsl.database.DataBase)2 Schema (org.obeonetwork.dsl.database.Schema)2 Root (org.obeonetwork.dsl.entity.Root)2 ScaffoldInfo (fr.gouv.mindef.safran.database.scaffold.ScaffoldInfo)1 File (java.io.File)1 IOException (java.io.IOException)1 InputStream (java.io.InputStream)1 ArrayList (java.util.ArrayList)1 HashSet (java.util.HashSet)1 ExecutionException (org.eclipse.core.commands.ExecutionException)1 IResource (org.eclipse.core.resources.IResource)1 BasicMonitor (org.eclipse.emf.common.util.BasicMonitor)1