Search in sources :

Example 1 with Expression

use of org.eclipse.xtext.example.arithmetics.arithmetics.Expression in project xtext-eclipse by eclipse.

the class MinusImpl method basicSetRight.

/**
 * <!-- begin-user-doc -->
 * <!-- end-user-doc -->
 * @generated
 */
public NotificationChain basicSetRight(Expression newRight, NotificationChain msgs) {
    Expression oldRight = right;
    right = newRight;
    if (eNotificationRequired()) {
        ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, ArithmeticsPackage.MINUS__RIGHT, oldRight, newRight);
        if (msgs == null)
            msgs = notification;
        else
            msgs.add(notification);
    }
    return msgs;
}
Also used : Expression(org.eclipse.xtext.example.arithmetics.arithmetics.Expression) ENotificationImpl(org.eclipse.emf.ecore.impl.ENotificationImpl)

Example 2 with Expression

use of org.eclipse.xtext.example.arithmetics.arithmetics.Expression in project xtext-eclipse by eclipse.

the class MinusImpl method basicSetLeft.

/**
 * <!-- begin-user-doc -->
 * <!-- end-user-doc -->
 * @generated
 */
public NotificationChain basicSetLeft(Expression newLeft, NotificationChain msgs) {
    Expression oldLeft = left;
    left = newLeft;
    if (eNotificationRequired()) {
        ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, ArithmeticsPackage.MINUS__LEFT, oldLeft, newLeft);
        if (msgs == null)
            msgs = notification;
        else
            msgs.add(notification);
    }
    return msgs;
}
Also used : Expression(org.eclipse.xtext.example.arithmetics.arithmetics.Expression) ENotificationImpl(org.eclipse.emf.ecore.impl.ENotificationImpl)

Example 3 with Expression

use of org.eclipse.xtext.example.arithmetics.arithmetics.Expression in project xtext-eclipse by eclipse.

the class MultiImpl method basicSetLeft.

/**
 * <!-- begin-user-doc -->
 * <!-- end-user-doc -->
 * @generated
 */
public NotificationChain basicSetLeft(Expression newLeft, NotificationChain msgs) {
    Expression oldLeft = left;
    left = newLeft;
    if (eNotificationRequired()) {
        ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, ArithmeticsPackage.MULTI__LEFT, oldLeft, newLeft);
        if (msgs == null)
            msgs = notification;
        else
            msgs.add(notification);
    }
    return msgs;
}
Also used : Expression(org.eclipse.xtext.example.arithmetics.arithmetics.Expression) ENotificationImpl(org.eclipse.emf.ecore.impl.ENotificationImpl)

Example 4 with Expression

use of org.eclipse.xtext.example.arithmetics.arithmetics.Expression in project xtext-eclipse by eclipse.

the class MultiImpl method basicSetRight.

/**
 * <!-- begin-user-doc -->
 * <!-- end-user-doc -->
 * @generated
 */
public NotificationChain basicSetRight(Expression newRight, NotificationChain msgs) {
    Expression oldRight = right;
    right = newRight;
    if (eNotificationRequired()) {
        ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, ArithmeticsPackage.MULTI__RIGHT, oldRight, newRight);
        if (msgs == null)
            msgs = notification;
        else
            msgs.add(notification);
    }
    return msgs;
}
Also used : Expression(org.eclipse.xtext.example.arithmetics.arithmetics.Expression) ENotificationImpl(org.eclipse.emf.ecore.impl.ENotificationImpl)

Example 5 with Expression

use of org.eclipse.xtext.example.arithmetics.arithmetics.Expression in project xtext-eclipse by eclipse.

the class PlusImpl method basicSetLeft.

/**
 * <!-- begin-user-doc -->
 * <!-- end-user-doc -->
 * @generated
 */
public NotificationChain basicSetLeft(Expression newLeft, NotificationChain msgs) {
    Expression oldLeft = left;
    left = newLeft;
    if (eNotificationRequired()) {
        ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, ArithmeticsPackage.PLUS__LEFT, oldLeft, newLeft);
        if (msgs == null)
            msgs = notification;
        else
            msgs.add(notification);
    }
    return msgs;
}
Also used : Expression(org.eclipse.xtext.example.arithmetics.arithmetics.Expression) ENotificationImpl(org.eclipse.emf.ecore.impl.ENotificationImpl)

Aggregations

Expression (org.eclipse.xtext.example.arithmetics.arithmetics.Expression)12 ENotificationImpl (org.eclipse.emf.ecore.impl.ENotificationImpl)10 BigDecimal (java.math.BigDecimal)2 Statement (org.eclipse.xtext.example.arithmetics.arithmetics.Statement)2 StringConcatenation (org.eclipse.xtend2.lib.StringConcatenation)1 Module (org.eclipse.xtext.example.arithmetics.arithmetics.Module)1