Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/infra/org.eclipse.papyrus.infra.extendedtypes/src-gen/org/eclipse/papyrus/infra/extendedtypes/impl/ExtendedElementTypeSetImpl.java')
-rw-r--r--plugins/infra/org.eclipse.papyrus.infra.extendedtypes/src-gen/org/eclipse/papyrus/infra/extendedtypes/impl/ExtendedElementTypeSetImpl.java454
1 files changed, 233 insertions, 221 deletions
diff --git a/plugins/infra/org.eclipse.papyrus.infra.extendedtypes/src-gen/org/eclipse/papyrus/infra/extendedtypes/impl/ExtendedElementTypeSetImpl.java b/plugins/infra/org.eclipse.papyrus.infra.extendedtypes/src-gen/org/eclipse/papyrus/infra/extendedtypes/impl/ExtendedElementTypeSetImpl.java
index 5f547c52d23..37fa2d10111 100644
--- a/plugins/infra/org.eclipse.papyrus.infra.extendedtypes/src-gen/org/eclipse/papyrus/infra/extendedtypes/impl/ExtendedElementTypeSetImpl.java
+++ b/plugins/infra/org.eclipse.papyrus.infra.extendedtypes/src-gen/org/eclipse/papyrus/infra/extendedtypes/impl/ExtendedElementTypeSetImpl.java
@@ -1,221 +1,233 @@
-/**
- * <copyright>
- * </copyright>
- *
- * $Id$
- */
-package org.eclipse.papyrus.infra.extendedtypes.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.impl.EObjectImpl;
-import org.eclipse.emf.ecore.util.EObjectContainmentEList;
-import org.eclipse.emf.ecore.util.InternalEList;
-import org.eclipse.papyrus.infra.extendedtypes.ExtendedElementTypeConfiguration;
-import org.eclipse.papyrus.infra.extendedtypes.ExtendedElementTypeSet;
-import org.eclipse.papyrus.infra.extendedtypes.ExtendedtypesPackage;
-
-/**
- * <!-- begin-user-doc -->
- * An implementation of the model object '<em><b>Extended Element Type Set</b></em>'.
- * <!-- end-user-doc -->
- * <p>
- * The following features are implemented:
- * <ul>
- * <li>{@link org.eclipse.papyrus.infra.extendedtypes.impl.ExtendedElementTypeSetImpl#getElementType <em>Element Type</em>}</li>
- * <li>{@link org.eclipse.papyrus.infra.extendedtypes.impl.ExtendedElementTypeSetImpl#getId <em>Id</em>}</li>
- * </ul>
- * </p>
- *
- * @generated
- */
-public class ExtendedElementTypeSetImpl extends EObjectImpl implements ExtendedElementTypeSet {
- /**
- * The cached value of the '{@link #getElementType() <em>Element Type</em>}' containment reference list.
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
- * @see #getElementType()
- * @generated
- * @ordered
- */
- protected EList<ExtendedElementTypeConfiguration> elementType;
-
- /**
- * The default value of the '{@link #getId() <em>Id</em>}' attribute.
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
- * @see #getId()
- * @generated
- * @ordered
- */
- protected static final String ID_EDEFAULT = null;
-
- /**
- * The cached value of the '{@link #getId() <em>Id</em>}' attribute.
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
- * @see #getId()
- * @generated
- * @ordered
- */
- protected String id = ID_EDEFAULT;
-
- /**
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
- * @generated
- */
- protected ExtendedElementTypeSetImpl() {
- super();
- }
-
- /**
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
- * @generated
- */
- @Override
- protected EClass eStaticClass() {
- return ExtendedtypesPackage.Literals.EXTENDED_ELEMENT_TYPE_SET;
- }
-
- /**
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
- * @generated
- */
- public EList<ExtendedElementTypeConfiguration> getElementType() {
- if (elementType == null) {
- elementType = new EObjectContainmentEList<ExtendedElementTypeConfiguration>(ExtendedElementTypeConfiguration.class, this, ExtendedtypesPackage.EXTENDED_ELEMENT_TYPE_SET__ELEMENT_TYPE);
- }
- return elementType;
- }
-
- /**
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
- * @generated
- */
- public String getId() {
- return id;
- }
-
- /**
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
- * @generated
- */
- public void setId(String newId) {
- String oldId = id;
- id = newId;
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET, ExtendedtypesPackage.EXTENDED_ELEMENT_TYPE_SET__ID, oldId, id));
- }
-
- /**
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
- * @generated
- */
- @Override
- public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
- switch (featureID) {
- case ExtendedtypesPackage.EXTENDED_ELEMENT_TYPE_SET__ELEMENT_TYPE:
- return ((InternalEList<?>)getElementType()).basicRemove(otherEnd, 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 ExtendedtypesPackage.EXTENDED_ELEMENT_TYPE_SET__ELEMENT_TYPE:
- return getElementType();
- case ExtendedtypesPackage.EXTENDED_ELEMENT_TYPE_SET__ID:
- return getId();
- }
- return super.eGet(featureID, resolve, coreType);
- }
-
- /**
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
- * @generated
- */
- @SuppressWarnings("unchecked")
- @Override
- public void eSet(int featureID, Object newValue) {
- switch (featureID) {
- case ExtendedtypesPackage.EXTENDED_ELEMENT_TYPE_SET__ELEMENT_TYPE:
- getElementType().clear();
- getElementType().addAll((Collection<? extends ExtendedElementTypeConfiguration>)newValue);
- return;
- case ExtendedtypesPackage.EXTENDED_ELEMENT_TYPE_SET__ID:
- setId((String)newValue);
- return;
- }
- super.eSet(featureID, newValue);
- }
-
- /**
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
- * @generated
- */
- @Override
- public void eUnset(int featureID) {
- switch (featureID) {
- case ExtendedtypesPackage.EXTENDED_ELEMENT_TYPE_SET__ELEMENT_TYPE:
- getElementType().clear();
- return;
- case ExtendedtypesPackage.EXTENDED_ELEMENT_TYPE_SET__ID:
- setId(ID_EDEFAULT);
- return;
- }
- super.eUnset(featureID);
- }
-
- /**
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
- * @generated
- */
- @Override
- public boolean eIsSet(int featureID) {
- switch (featureID) {
- case ExtendedtypesPackage.EXTENDED_ELEMENT_TYPE_SET__ELEMENT_TYPE:
- return elementType != null && !elementType.isEmpty();
- case ExtendedtypesPackage.EXTENDED_ELEMENT_TYPE_SET__ID:
- return ID_EDEFAULT == null ? id != null : !ID_EDEFAULT.equals(id);
- }
- return super.eIsSet(featureID);
- }
-
- /**
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
- * @generated
- */
- @Override
- public String toString() {
- if (eIsProxy()) return super.toString();
-
- StringBuffer result = new StringBuffer(super.toString());
- result.append(" (id: ");
- result.append(id);
- result.append(')');
- return result.toString();
- }
-
-} //ExtendedElementTypeSetImpl
+/**
+ * Copyright (c) 2013 CEA LIST.
+ *
+ *
+ * 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:
+ * CEA LIST - Initial API and implementation
+ */
+package org.eclipse.papyrus.infra.extendedtypes.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.eclipse.papyrus.infra.extendedtypes.ElementTypeConfiguration;
+import org.eclipse.papyrus.infra.extendedtypes.ExtendedElementTypeSet;
+import org.eclipse.papyrus.infra.extendedtypes.ExtendedtypesPackage;
+
+/**
+ * <!-- begin-user-doc --> An implementation of the model object ' <em><b>Extended Element Type Set</b></em>'. <!-- end-user-doc -->
+ * <p>
+ * The following features are implemented:
+ * <ul>
+ * <li>{@link org.eclipse.papyrus.infra.extendedtypes.impl.ExtendedElementTypeSetImpl#getElementType <em>Element Type</em>}</li>
+ * <li>{@link org.eclipse.papyrus.infra.extendedtypes.impl.ExtendedElementTypeSetImpl#isExtensible <em>Extensible</em>}</li>
+ * </ul>
+ * </p>
+ *
+ * @generated
+ */
+public class ExtendedElementTypeSetImpl extends ConfigurationElementImpl implements ExtendedElementTypeSet {
+
+ /**
+ * The cached value of the '{@link #getElementType() <em>Element Type</em>}' containment reference list.
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @see #getElementType()
+ * @generated
+ * @ordered
+ */
+ protected EList<ElementTypeConfiguration> elementType;
+
+ /**
+ * The default value of the '{@link #isExtensible() <em>Extensible</em>}' attribute.
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ *
+ * @see #isExtensible()
+ * @generated
+ * @ordered
+ */
+ protected static final boolean EXTENSIBLE_EDEFAULT = false;
+
+ /**
+ * The cached value of the '{@link #isExtensible() <em>Extensible</em>}' attribute.
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ *
+ * @see #isExtensible()
+ * @generated
+ * @ordered
+ */
+ protected boolean extensible = EXTENSIBLE_EDEFAULT;
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ protected ExtendedElementTypeSetImpl() {
+ super();
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ @Override
+ protected EClass eStaticClass() {
+ return ExtendedtypesPackage.eINSTANCE.getExtendedElementTypeSet();
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public EList<ElementTypeConfiguration> getElementType() {
+ if(elementType == null) {
+ elementType = new EObjectContainmentEList<ElementTypeConfiguration>(ElementTypeConfiguration.class, this, ExtendedtypesPackage.EXTENDED_ELEMENT_TYPE_SET__ELEMENT_TYPE);
+ }
+ return elementType;
+ }
+
+ /**
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public boolean isExtensible() {
+ return extensible;
+ }
+
+ /**
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ public void setExtensible(boolean newExtensible) {
+ boolean oldExtensible = extensible;
+ extensible = newExtensible;
+ if(eNotificationRequired())
+ eNotify(new ENotificationImpl(this, Notification.SET, ExtendedtypesPackage.EXTENDED_ELEMENT_TYPE_SET__EXTENSIBLE, oldExtensible, extensible));
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ @Override
+ public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
+ switch(featureID) {
+ case ExtendedtypesPackage.EXTENDED_ELEMENT_TYPE_SET__ELEMENT_TYPE:
+ return ((InternalEList<?>)getElementType()).basicRemove(otherEnd, 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 ExtendedtypesPackage.EXTENDED_ELEMENT_TYPE_SET__ELEMENT_TYPE:
+ return getElementType();
+ case ExtendedtypesPackage.EXTENDED_ELEMENT_TYPE_SET__EXTENSIBLE:
+ return isExtensible();
+ }
+ return super.eGet(featureID, resolve, coreType);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ @SuppressWarnings("unchecked")
+ @Override
+ public void eSet(int featureID, Object newValue) {
+ switch(featureID) {
+ case ExtendedtypesPackage.EXTENDED_ELEMENT_TYPE_SET__ELEMENT_TYPE:
+ getElementType().clear();
+ getElementType().addAll((Collection<? extends ElementTypeConfiguration>)newValue);
+ return;
+ case ExtendedtypesPackage.EXTENDED_ELEMENT_TYPE_SET__EXTENSIBLE:
+ setExtensible((Boolean)newValue);
+ return;
+ }
+ super.eSet(featureID, newValue);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ @Override
+ public void eUnset(int featureID) {
+ switch(featureID) {
+ case ExtendedtypesPackage.EXTENDED_ELEMENT_TYPE_SET__ELEMENT_TYPE:
+ getElementType().clear();
+ return;
+ case ExtendedtypesPackage.EXTENDED_ELEMENT_TYPE_SET__EXTENSIBLE:
+ setExtensible(EXTENSIBLE_EDEFAULT);
+ return;
+ }
+ super.eUnset(featureID);
+ }
+
+ /**
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ @Override
+ public boolean eIsSet(int featureID) {
+ switch(featureID) {
+ case ExtendedtypesPackage.EXTENDED_ELEMENT_TYPE_SET__ELEMENT_TYPE:
+ return elementType != null && !elementType.isEmpty();
+ case ExtendedtypesPackage.EXTENDED_ELEMENT_TYPE_SET__EXTENSIBLE:
+ return extensible != EXTENSIBLE_EDEFAULT;
+ }
+ return super.eIsSet(featureID);
+ }
+
+ /**
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ *
+ * @generated
+ */
+ @Override
+ public String toString() {
+ if(eIsProxy())
+ return super.toString();
+ StringBuffer result = new StringBuffer(super.toString());
+ result.append(" (extensible: "); //$NON-NLS-1$
+ result.append(extensible);
+ result.append(')');
+ return result.toString();
+ }
+} // ExtendedElementTypeSetImpl

Back to the top