| /** |
| * Copyright (c) 2008, 2021 Obeo. |
| * |
| * All rights reserved. This program and the accompanying materials |
| * are made available under the terms of the Eclipse Public License v1.0 |
| * which accompanies this distribution, and is available at |
| * http://www.eclipse.org/legal/epl-v10.html |
| * |
| * Contributors: |
| * Obeo - initial API and implementation |
| */ |
| package org.eclipse.acceleo.impl; |
| |
| import org.eclipse.acceleo.AcceleoPackage; |
| import org.eclipse.acceleo.Binding; |
| import org.eclipse.acceleo.Block; |
| import org.eclipse.acceleo.ErrorForStatement; |
| import org.eclipse.acceleo.Expression; |
| import org.eclipse.acceleo.ForStatement; |
| import org.eclipse.acceleo.Statement; |
| import org.eclipse.emf.common.notify.Notification; |
| import org.eclipse.emf.common.notify.NotificationChain; |
| import org.eclipse.emf.ecore.EClass; |
| import org.eclipse.emf.ecore.InternalEObject; |
| import org.eclipse.emf.ecore.impl.ENotificationImpl; |
| import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; |
| |
| /** |
| * <!-- begin-user-doc --> An implementation of the model object '<em><b>Error For Statement</b></em>'. <!-- |
| * end-user-doc --> |
| * <p> |
| * The following features are implemented: |
| * </p> |
| * <ul> |
| * <li>{@link org.eclipse.acceleo.impl.ErrorForStatementImpl#getBinding <em>Binding</em>}</li> |
| * <li>{@link org.eclipse.acceleo.impl.ErrorForStatementImpl#getSeparator <em>Separator</em>}</li> |
| * <li>{@link org.eclipse.acceleo.impl.ErrorForStatementImpl#getBody <em>Body</em>}</li> |
| * <li>{@link org.eclipse.acceleo.impl.ErrorForStatementImpl#getMissingOpenParenthesis <em>Missing Open |
| * Parenthesis</em>}</li> |
| * <li>{@link org.eclipse.acceleo.impl.ErrorForStatementImpl#getMissingBinding <em>Missing Binding</em>}</li> |
| * <li>{@link org.eclipse.acceleo.impl.ErrorForStatementImpl#getMissingCloseParenthesis <em>Missing Close |
| * Parenthesis</em>}</li> |
| * <li>{@link org.eclipse.acceleo.impl.ErrorForStatementImpl#getMissingSeparatorCloseParenthesis <em>Missing |
| * Separator Close Parenthesis</em>}</li> |
| * <li>{@link org.eclipse.acceleo.impl.ErrorForStatementImpl#getMissingEndHeader <em>Missing End |
| * Header</em>}</li> |
| * <li>{@link org.eclipse.acceleo.impl.ErrorForStatementImpl#getMissingEnd <em>Missing End</em>}</li> |
| * </ul> |
| * |
| * @generated |
| */ |
| public class ErrorForStatementImpl extends MinimalEObjectImpl.Container implements ErrorForStatement { |
| /** |
| * The cached value of the '{@link #getBinding() <em>Binding</em>}' containment reference. <!-- |
| * begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @see #getBinding() |
| * @generated |
| * @ordered |
| */ |
| protected Binding binding; |
| |
| /** |
| * The cached value of the '{@link #getSeparator() <em>Separator</em>}' containment reference. <!-- |
| * begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @see #getSeparator() |
| * @generated |
| * @ordered |
| */ |
| protected Expression separator; |
| |
| /** |
| * The cached value of the '{@link #getBody() <em>Body</em>}' containment reference. <!-- begin-user-doc |
| * --> <!-- end-user-doc --> |
| * |
| * @see #getBody() |
| * @generated |
| * @ordered |
| */ |
| protected Block body; |
| |
| /** |
| * The default value of the '{@link #getMissingOpenParenthesis() <em>Missing Open Parenthesis</em>}' |
| * attribute. <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @see #getMissingOpenParenthesis() |
| * @generated |
| * @ordered |
| */ |
| protected static final int MISSING_OPEN_PARENTHESIS_EDEFAULT = -1; |
| |
| /** |
| * The cached value of the '{@link #getMissingOpenParenthesis() <em>Missing Open Parenthesis</em>}' |
| * attribute. <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @see #getMissingOpenParenthesis() |
| * @generated |
| * @ordered |
| */ |
| protected int missingOpenParenthesis = MISSING_OPEN_PARENTHESIS_EDEFAULT; |
| |
| /** |
| * The default value of the '{@link #getMissingBinding() <em>Missing Binding</em>}' attribute. <!-- |
| * begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @see #getMissingBinding() |
| * @generated |
| * @ordered |
| */ |
| protected static final int MISSING_BINDING_EDEFAULT = -1; |
| |
| /** |
| * The cached value of the '{@link #getMissingBinding() <em>Missing Binding</em>}' attribute. <!-- |
| * begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @see #getMissingBinding() |
| * @generated |
| * @ordered |
| */ |
| protected int missingBinding = MISSING_BINDING_EDEFAULT; |
| |
| /** |
| * The default value of the '{@link #getMissingCloseParenthesis() <em>Missing Close Parenthesis</em>}' |
| * attribute. <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @see #getMissingCloseParenthesis() |
| * @generated |
| * @ordered |
| */ |
| protected static final int MISSING_CLOSE_PARENTHESIS_EDEFAULT = -1; |
| |
| /** |
| * The cached value of the '{@link #getMissingCloseParenthesis() <em>Missing Close Parenthesis</em>}' |
| * attribute. <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @see #getMissingCloseParenthesis() |
| * @generated |
| * @ordered |
| */ |
| protected int missingCloseParenthesis = MISSING_CLOSE_PARENTHESIS_EDEFAULT; |
| |
| /** |
| * The default value of the '{@link #getMissingSeparatorCloseParenthesis() <em>Missing Separator Close |
| * Parenthesis</em>}' attribute. <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @see #getMissingSeparatorCloseParenthesis() |
| * @generated |
| * @ordered |
| */ |
| protected static final int MISSING_SEPARATOR_CLOSE_PARENTHESIS_EDEFAULT = -1; |
| |
| /** |
| * The cached value of the '{@link #getMissingSeparatorCloseParenthesis() <em>Missing Separator Close |
| * Parenthesis</em>}' attribute. <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @see #getMissingSeparatorCloseParenthesis() |
| * @generated |
| * @ordered |
| */ |
| protected int missingSeparatorCloseParenthesis = MISSING_SEPARATOR_CLOSE_PARENTHESIS_EDEFAULT; |
| |
| /** |
| * The default value of the '{@link #getMissingEndHeader() <em>Missing End Header</em>}' attribute. <!-- |
| * begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @see #getMissingEndHeader() |
| * @generated |
| * @ordered |
| */ |
| protected static final int MISSING_END_HEADER_EDEFAULT = -1; |
| |
| /** |
| * The cached value of the '{@link #getMissingEndHeader() <em>Missing End Header</em>}' attribute. <!-- |
| * begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @see #getMissingEndHeader() |
| * @generated |
| * @ordered |
| */ |
| protected int missingEndHeader = MISSING_END_HEADER_EDEFAULT; |
| |
| /** |
| * The default value of the '{@link #getMissingEnd() <em>Missing End</em>}' attribute. <!-- begin-user-doc |
| * --> <!-- end-user-doc --> |
| * |
| * @see #getMissingEnd() |
| * @generated |
| * @ordered |
| */ |
| protected static final int MISSING_END_EDEFAULT = -1; |
| |
| /** |
| * The cached value of the '{@link #getMissingEnd() <em>Missing End</em>}' attribute. <!-- begin-user-doc |
| * --> <!-- end-user-doc --> |
| * |
| * @see #getMissingEnd() |
| * @generated |
| * @ordered |
| */ |
| protected int missingEnd = MISSING_END_EDEFAULT; |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| protected ErrorForStatementImpl() { |
| super(); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| protected EClass eStaticClass() { |
| return AcceleoPackage.Literals.ERROR_FOR_STATEMENT; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public Binding getBinding() { |
| return binding; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| public NotificationChain basicSetBinding(Binding newBinding, NotificationChain msgs) { |
| Binding oldBinding = binding; |
| binding = newBinding; |
| if (eNotificationRequired()) { |
| ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, |
| AcceleoPackage.ERROR_FOR_STATEMENT__BINDING, oldBinding, newBinding); |
| if (msgs == null) |
| msgs = notification; |
| else |
| msgs.add(notification); |
| } |
| return msgs; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public void setBinding(Binding newBinding) { |
| if (newBinding != binding) { |
| NotificationChain msgs = null; |
| if (binding != null) |
| msgs = ((InternalEObject)binding).eInverseRemove(this, EOPPOSITE_FEATURE_BASE |
| - AcceleoPackage.ERROR_FOR_STATEMENT__BINDING, null, msgs); |
| if (newBinding != null) |
| msgs = ((InternalEObject)newBinding).eInverseAdd(this, EOPPOSITE_FEATURE_BASE |
| - AcceleoPackage.ERROR_FOR_STATEMENT__BINDING, null, msgs); |
| msgs = basicSetBinding(newBinding, msgs); |
| if (msgs != null) |
| msgs.dispatch(); |
| } else if (eNotificationRequired()) |
| eNotify(new ENotificationImpl(this, Notification.SET, AcceleoPackage.ERROR_FOR_STATEMENT__BINDING, |
| newBinding, newBinding)); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public Expression getSeparator() { |
| return separator; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| public NotificationChain basicSetSeparator(Expression newSeparator, NotificationChain msgs) { |
| Expression oldSeparator = separator; |
| separator = newSeparator; |
| if (eNotificationRequired()) { |
| ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, |
| AcceleoPackage.ERROR_FOR_STATEMENT__SEPARATOR, oldSeparator, newSeparator); |
| if (msgs == null) |
| msgs = notification; |
| else |
| msgs.add(notification); |
| } |
| return msgs; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public void setSeparator(Expression newSeparator) { |
| if (newSeparator != separator) { |
| NotificationChain msgs = null; |
| if (separator != null) |
| msgs = ((InternalEObject)separator).eInverseRemove(this, EOPPOSITE_FEATURE_BASE |
| - AcceleoPackage.ERROR_FOR_STATEMENT__SEPARATOR, null, msgs); |
| if (newSeparator != null) |
| msgs = ((InternalEObject)newSeparator).eInverseAdd(this, EOPPOSITE_FEATURE_BASE |
| - AcceleoPackage.ERROR_FOR_STATEMENT__SEPARATOR, null, msgs); |
| msgs = basicSetSeparator(newSeparator, msgs); |
| if (msgs != null) |
| msgs.dispatch(); |
| } else if (eNotificationRequired()) |
| eNotify(new ENotificationImpl(this, Notification.SET, |
| AcceleoPackage.ERROR_FOR_STATEMENT__SEPARATOR, newSeparator, newSeparator)); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public Block getBody() { |
| return body; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| public NotificationChain basicSetBody(Block newBody, NotificationChain msgs) { |
| Block oldBody = body; |
| body = newBody; |
| if (eNotificationRequired()) { |
| ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, |
| AcceleoPackage.ERROR_FOR_STATEMENT__BODY, oldBody, newBody); |
| if (msgs == null) |
| msgs = notification; |
| else |
| msgs.add(notification); |
| } |
| return msgs; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public void setBody(Block newBody) { |
| if (newBody != body) { |
| NotificationChain msgs = null; |
| if (body != null) |
| msgs = ((InternalEObject)body).eInverseRemove(this, EOPPOSITE_FEATURE_BASE |
| - AcceleoPackage.ERROR_FOR_STATEMENT__BODY, null, msgs); |
| if (newBody != null) |
| msgs = ((InternalEObject)newBody).eInverseAdd(this, EOPPOSITE_FEATURE_BASE |
| - AcceleoPackage.ERROR_FOR_STATEMENT__BODY, null, msgs); |
| msgs = basicSetBody(newBody, msgs); |
| if (msgs != null) |
| msgs.dispatch(); |
| } else if (eNotificationRequired()) |
| eNotify(new ENotificationImpl(this, Notification.SET, AcceleoPackage.ERROR_FOR_STATEMENT__BODY, |
| newBody, newBody)); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public int getMissingOpenParenthesis() { |
| return missingOpenParenthesis; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public void setMissingOpenParenthesis(int newMissingOpenParenthesis) { |
| int oldMissingOpenParenthesis = missingOpenParenthesis; |
| missingOpenParenthesis = newMissingOpenParenthesis; |
| if (eNotificationRequired()) |
| eNotify(new ENotificationImpl(this, Notification.SET, |
| AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_OPEN_PARENTHESIS, oldMissingOpenParenthesis, |
| missingOpenParenthesis)); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public int getMissingBinding() { |
| return missingBinding; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public void setMissingBinding(int newMissingBinding) { |
| int oldMissingBinding = missingBinding; |
| missingBinding = newMissingBinding; |
| if (eNotificationRequired()) |
| eNotify(new ENotificationImpl(this, Notification.SET, |
| AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_BINDING, oldMissingBinding, missingBinding)); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public int getMissingCloseParenthesis() { |
| return missingCloseParenthesis; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public void setMissingCloseParenthesis(int newMissingCloseParenthesis) { |
| int oldMissingCloseParenthesis = missingCloseParenthesis; |
| missingCloseParenthesis = newMissingCloseParenthesis; |
| if (eNotificationRequired()) |
| eNotify(new ENotificationImpl(this, Notification.SET, |
| AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_CLOSE_PARENTHESIS, oldMissingCloseParenthesis, |
| missingCloseParenthesis)); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public int getMissingSeparatorCloseParenthesis() { |
| return missingSeparatorCloseParenthesis; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public void setMissingSeparatorCloseParenthesis(int newMissingSeparatorCloseParenthesis) { |
| int oldMissingSeparatorCloseParenthesis = missingSeparatorCloseParenthesis; |
| missingSeparatorCloseParenthesis = newMissingSeparatorCloseParenthesis; |
| if (eNotificationRequired()) |
| eNotify(new ENotificationImpl(this, Notification.SET, |
| AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_SEPARATOR_CLOSE_PARENTHESIS, |
| oldMissingSeparatorCloseParenthesis, missingSeparatorCloseParenthesis)); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public int getMissingEndHeader() { |
| return missingEndHeader; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public void setMissingEndHeader(int newMissingEndHeader) { |
| int oldMissingEndHeader = missingEndHeader; |
| missingEndHeader = newMissingEndHeader; |
| if (eNotificationRequired()) |
| eNotify(new ENotificationImpl(this, Notification.SET, |
| AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_END_HEADER, oldMissingEndHeader, |
| missingEndHeader)); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public int getMissingEnd() { |
| return missingEnd; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public void setMissingEnd(int newMissingEnd) { |
| int oldMissingEnd = missingEnd; |
| missingEnd = newMissingEnd; |
| if (eNotificationRequired()) |
| eNotify(new ENotificationImpl(this, Notification.SET, |
| AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_END, oldMissingEnd, missingEnd)); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { |
| switch (featureID) { |
| case AcceleoPackage.ERROR_FOR_STATEMENT__BINDING: |
| return basicSetBinding(null, msgs); |
| case AcceleoPackage.ERROR_FOR_STATEMENT__SEPARATOR: |
| return basicSetSeparator(null, msgs); |
| case AcceleoPackage.ERROR_FOR_STATEMENT__BODY: |
| return basicSetBody(null, msgs); |
| } |
| return super.eInverseRemove(otherEnd, featureID, msgs); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public Object eGet(int featureID, boolean resolve, boolean coreType) { |
| switch (featureID) { |
| case AcceleoPackage.ERROR_FOR_STATEMENT__BINDING: |
| return getBinding(); |
| case AcceleoPackage.ERROR_FOR_STATEMENT__SEPARATOR: |
| return getSeparator(); |
| case AcceleoPackage.ERROR_FOR_STATEMENT__BODY: |
| return getBody(); |
| case AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_OPEN_PARENTHESIS: |
| return getMissingOpenParenthesis(); |
| case AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_BINDING: |
| return getMissingBinding(); |
| case AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_CLOSE_PARENTHESIS: |
| return getMissingCloseParenthesis(); |
| case AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_SEPARATOR_CLOSE_PARENTHESIS: |
| return getMissingSeparatorCloseParenthesis(); |
| case AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_END_HEADER: |
| return getMissingEndHeader(); |
| case AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_END: |
| return getMissingEnd(); |
| } |
| return super.eGet(featureID, resolve, coreType); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public void eSet(int featureID, Object newValue) { |
| switch (featureID) { |
| case AcceleoPackage.ERROR_FOR_STATEMENT__BINDING: |
| setBinding((Binding)newValue); |
| return; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__SEPARATOR: |
| setSeparator((Expression)newValue); |
| return; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__BODY: |
| setBody((Block)newValue); |
| return; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_OPEN_PARENTHESIS: |
| setMissingOpenParenthesis((Integer)newValue); |
| return; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_BINDING: |
| setMissingBinding((Integer)newValue); |
| return; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_CLOSE_PARENTHESIS: |
| setMissingCloseParenthesis((Integer)newValue); |
| return; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_SEPARATOR_CLOSE_PARENTHESIS: |
| setMissingSeparatorCloseParenthesis((Integer)newValue); |
| return; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_END_HEADER: |
| setMissingEndHeader((Integer)newValue); |
| return; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_END: |
| setMissingEnd((Integer)newValue); |
| return; |
| } |
| super.eSet(featureID, newValue); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public void eUnset(int featureID) { |
| switch (featureID) { |
| case AcceleoPackage.ERROR_FOR_STATEMENT__BINDING: |
| setBinding((Binding)null); |
| return; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__SEPARATOR: |
| setSeparator((Expression)null); |
| return; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__BODY: |
| setBody((Block)null); |
| return; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_OPEN_PARENTHESIS: |
| setMissingOpenParenthesis(MISSING_OPEN_PARENTHESIS_EDEFAULT); |
| return; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_BINDING: |
| setMissingBinding(MISSING_BINDING_EDEFAULT); |
| return; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_CLOSE_PARENTHESIS: |
| setMissingCloseParenthesis(MISSING_CLOSE_PARENTHESIS_EDEFAULT); |
| return; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_SEPARATOR_CLOSE_PARENTHESIS: |
| setMissingSeparatorCloseParenthesis(MISSING_SEPARATOR_CLOSE_PARENTHESIS_EDEFAULT); |
| return; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_END_HEADER: |
| setMissingEndHeader(MISSING_END_HEADER_EDEFAULT); |
| return; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_END: |
| setMissingEnd(MISSING_END_EDEFAULT); |
| return; |
| } |
| super.eUnset(featureID); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public boolean eIsSet(int featureID) { |
| switch (featureID) { |
| case AcceleoPackage.ERROR_FOR_STATEMENT__BINDING: |
| return binding != null; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__SEPARATOR: |
| return separator != null; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__BODY: |
| return body != null; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_OPEN_PARENTHESIS: |
| return missingOpenParenthesis != MISSING_OPEN_PARENTHESIS_EDEFAULT; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_BINDING: |
| return missingBinding != MISSING_BINDING_EDEFAULT; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_CLOSE_PARENTHESIS: |
| return missingCloseParenthesis != MISSING_CLOSE_PARENTHESIS_EDEFAULT; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_SEPARATOR_CLOSE_PARENTHESIS: |
| return missingSeparatorCloseParenthesis != MISSING_SEPARATOR_CLOSE_PARENTHESIS_EDEFAULT; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_END_HEADER: |
| return missingEndHeader != MISSING_END_HEADER_EDEFAULT; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__MISSING_END: |
| return missingEnd != MISSING_END_EDEFAULT; |
| } |
| return super.eIsSet(featureID); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public int eBaseStructuralFeatureID(int derivedFeatureID, Class<?> baseClass) { |
| if (baseClass == Statement.class) { |
| switch (derivedFeatureID) { |
| default: |
| return -1; |
| } |
| } |
| if (baseClass == ForStatement.class) { |
| switch (derivedFeatureID) { |
| case AcceleoPackage.ERROR_FOR_STATEMENT__BINDING: |
| return AcceleoPackage.FOR_STATEMENT__BINDING; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__SEPARATOR: |
| return AcceleoPackage.FOR_STATEMENT__SEPARATOR; |
| case AcceleoPackage.ERROR_FOR_STATEMENT__BODY: |
| return AcceleoPackage.FOR_STATEMENT__BODY; |
| default: |
| return -1; |
| } |
| } |
| return super.eBaseStructuralFeatureID(derivedFeatureID, baseClass); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public int eDerivedStructuralFeatureID(int baseFeatureID, Class<?> baseClass) { |
| if (baseClass == Statement.class) { |
| switch (baseFeatureID) { |
| default: |
| return -1; |
| } |
| } |
| if (baseClass == ForStatement.class) { |
| switch (baseFeatureID) { |
| case AcceleoPackage.FOR_STATEMENT__BINDING: |
| return AcceleoPackage.ERROR_FOR_STATEMENT__BINDING; |
| case AcceleoPackage.FOR_STATEMENT__SEPARATOR: |
| return AcceleoPackage.ERROR_FOR_STATEMENT__SEPARATOR; |
| case AcceleoPackage.FOR_STATEMENT__BODY: |
| return AcceleoPackage.ERROR_FOR_STATEMENT__BODY; |
| default: |
| return -1; |
| } |
| } |
| return super.eDerivedStructuralFeatureID(baseFeatureID, baseClass); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> <!-- end-user-doc --> |
| * |
| * @generated |
| */ |
| @Override |
| public String toString() { |
| if (eIsProxy()) |
| return super.toString(); |
| |
| StringBuilder result = new StringBuilder(super.toString()); |
| result.append(" (missingOpenParenthesis: "); //$NON-NLS-1$ |
| result.append(missingOpenParenthesis); |
| result.append(", missingBinding: "); //$NON-NLS-1$ |
| result.append(missingBinding); |
| result.append(", missingCloseParenthesis: "); //$NON-NLS-1$ |
| result.append(missingCloseParenthesis); |
| result.append(", missingSeparatorCloseParenthesis: "); //$NON-NLS-1$ |
| result.append(missingSeparatorCloseParenthesis); |
| result.append(", missingEndHeader: "); //$NON-NLS-1$ |
| result.append(missingEndHeader); |
| result.append(", missingEnd: "); //$NON-NLS-1$ |
| result.append(missingEnd); |
| result.append(')'); |
| return result.toString(); |
| } |
| |
| } // ErrorForStatementImpl |