Search in sources :

Example 1 with AddPrimaryKey

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

the class AddPrimaryKeyItemProvider method getText.

/**
 * This returns the label text for the adapted class.
 * <!-- begin-user-doc -->
 * <!-- end-user-doc -->
 * @generated NOT
 */
@Override
public String getText(Object object) {
    AddPrimaryKey addPrimaryKey = (AddPrimaryKey) object;
    PrimaryKey primaryKey = addPrimaryKey.getPrimaryKey();
    if (primaryKey != null) {
        return getString("_UI_AddPrimaryKey_type") + " " + primaryKey.getName();
    } else {
        return getString("_UI_AddPrimaryKey_type");
    }
}
Also used : PrimaryKey(org.obeonetwork.dsl.database.PrimaryKey) AddPrimaryKey(org.obeonetwork.dsl.database.dbevolution.AddPrimaryKey) AddPrimaryKey(org.obeonetwork.dsl.database.dbevolution.AddPrimaryKey)

Example 2 with AddPrimaryKey

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

the class PrimaryKeyChangeBuilder method createAddPrimaryKey.

protected AddPrimaryKey createAddPrimaryKey(PrimaryKey pk, ReferenceChange change) {
    AddPrimaryKey addPK = DbevolutionFactory.eINSTANCE.createAddPrimaryKey();
    addPK.setPrimaryKey(pk);
    fillDBDiff(addPK, change);
    return addPK;
}
Also used : AddPrimaryKey(org.obeonetwork.dsl.database.dbevolution.AddPrimaryKey)

Aggregations

AddPrimaryKey (org.obeonetwork.dsl.database.dbevolution.AddPrimaryKey)2 PrimaryKey (org.obeonetwork.dsl.database.PrimaryKey)1