Search in sources :

Example 1 with GRelationOperator

use of org.eclipse.gemoc.gexpressions.GRelationOperator in project gemoc-studio by eclipse.

the class GRelationExpressionImpl method setOperator.

/**
 * <!-- begin-user-doc -->
 * <!-- end-user-doc -->
 * @generated
 */
public void setOperator(GRelationOperator newOperator) {
    GRelationOperator oldOperator = operator;
    operator = newOperator == null ? OPERATOR_EDEFAULT : newOperator;
    if (eNotificationRequired())
        eNotify(new ENotificationImpl(this, Notification.SET, GexpressionsPackage.GRELATION_EXPRESSION__OPERATOR, oldOperator, operator));
}
Also used : ENotificationImpl(org.eclipse.emf.ecore.impl.ENotificationImpl) GRelationOperator(org.eclipse.gemoc.gexpressions.GRelationOperator)

Example 2 with GRelationOperator

use of org.eclipse.gemoc.gexpressions.GRelationOperator in project gemoc-studio by eclipse.

the class GRelationExpressionItemProvider method getText.

/**
 * This returns the label text for the adapted class.
 * <!-- begin-user-doc -->
 * <!-- end-user-doc -->
 * @generated
 */
@Override
public String getText(Object object) {
    GRelationOperator labelValue = ((GRelationExpression) object).getOperator();
    String label = labelValue == null ? null : labelValue.toString();
    return label == null || label.length() == 0 ? getString("_UI_GRelationExpression_type") : getString("_UI_GRelationExpression_type") + " " + label;
}
Also used : GRelationExpression(org.eclipse.gemoc.gexpressions.GRelationExpression) GRelationOperator(org.eclipse.gemoc.gexpressions.GRelationOperator)

Aggregations

GRelationOperator (org.eclipse.gemoc.gexpressions.GRelationOperator)2 ENotificationImpl (org.eclipse.emf.ecore.impl.ENotificationImpl)1 GRelationExpression (org.eclipse.gemoc.gexpressions.GRelationExpression)1