All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.openxma.dsl.dom.model.impl.SelectClassImpl Maven / Gradle / Ivy

There is a newer version: 6.0.2
Show newest version
/**
 * 
 * 
 *
 * $Id$
 */
package org.openxma.dsl.dom.model.impl;

import java.util.Collection;

import org.eclipse.emf.common.notify.Notification;
import org.eclipse.emf.common.notify.NotificationChain;
import org.eclipse.emf.common.util.EList;
import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.ecore.InternalEObject;
import org.eclipse.emf.ecore.impl.ENotificationImpl;
import org.eclipse.emf.ecore.util.EObjectContainmentEList;
import org.eclipse.emf.ecore.util.InternalEList;
import org.openxma.dsl.dom.DomPackage;
import org.openxma.dsl.dom.model.Expression;
import org.openxma.dsl.dom.model.SelectClass;

/**
 * 
 * An implementation of the model object 'Select Class'.
 * 
 * 

* The following features are implemented: *

    *
  • {@link org.openxma.dsl.dom.model.impl.SelectClassImpl#getClass_ Class}
  • *
  • {@link org.openxma.dsl.dom.model.impl.SelectClassImpl#getArguments Arguments}
  • *
*

* * @generated */ public class SelectClassImpl extends SelectStatementImpl implements SelectClass { /** * The default value of the '{@link #getClass_() Class}' attribute. * * * @see #getClass_() * @generated * @ordered */ protected static final String CLASS_EDEFAULT = null; /** * The cached value of the '{@link #getClass_() Class}' attribute. * * * @see #getClass_() * @generated * @ordered */ protected String class_ = CLASS_EDEFAULT; /** * The cached value of the '{@link #getArguments() Arguments}' containment reference list. * * * @see #getArguments() * @generated * @ordered */ protected EList arguments; /** * * * @generated */ protected SelectClassImpl() { super(); } /** * * * @generated */ @Override protected EClass eStaticClass() { return DomPackage.Literals.SELECT_CLASS; } /** * * * @generated */ public String getClass_() { return class_; } /** * * * @generated */ public void setClass(String newClass) { String oldClass = class_; class_ = newClass; if (eNotificationRequired()) eNotify(new ENotificationImpl(this, Notification.SET, DomPackage.SELECT_CLASS__CLASS, oldClass, class_)); } /** * * * @generated */ public EList getArguments() { if (arguments == null) { arguments = new EObjectContainmentEList(Expression.class, this, DomPackage.SELECT_CLASS__ARGUMENTS); } return arguments; } /** * * * @generated */ @Override public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { switch (featureID) { case DomPackage.SELECT_CLASS__ARGUMENTS: return ((InternalEList)getArguments()).basicRemove(otherEnd, msgs); } return super.eInverseRemove(otherEnd, featureID, msgs); } /** * * * @generated */ @Override public Object eGet(int featureID, boolean resolve, boolean coreType) { switch (featureID) { case DomPackage.SELECT_CLASS__CLASS: return getClass_(); case DomPackage.SELECT_CLASS__ARGUMENTS: return getArguments(); } return super.eGet(featureID, resolve, coreType); } /** * * * @generated */ @SuppressWarnings("unchecked") @Override public void eSet(int featureID, Object newValue) { switch (featureID) { case DomPackage.SELECT_CLASS__CLASS: setClass((String)newValue); return; case DomPackage.SELECT_CLASS__ARGUMENTS: getArguments().clear(); getArguments().addAll((Collection)newValue); return; } super.eSet(featureID, newValue); } /** * * * @generated */ @Override public void eUnset(int featureID) { switch (featureID) { case DomPackage.SELECT_CLASS__CLASS: setClass(CLASS_EDEFAULT); return; case DomPackage.SELECT_CLASS__ARGUMENTS: getArguments().clear(); return; } super.eUnset(featureID); } /** * * * @generated */ @Override public boolean eIsSet(int featureID) { switch (featureID) { case DomPackage.SELECT_CLASS__CLASS: return CLASS_EDEFAULT == null ? class_ != null : !CLASS_EDEFAULT.equals(class_); case DomPackage.SELECT_CLASS__ARGUMENTS: return arguments != null && !arguments.isEmpty(); } return super.eIsSet(featureID); } /** * * * @generated */ @Override public String toString() { if (eIsProxy()) return super.toString(); StringBuffer result = new StringBuffer(super.toString()); result.append(" (class: "); result.append(class_); result.append(')'); return result.toString(); } } //SelectClassImpl




© 2015 - 2024 Weber Informatics LLC | Privacy Policy