| /** |
| */ |
| package io.shell.admin.aas._2._0.impl; |
| |
| import io.shell.admin.aas._2._0.DataElementAbstractT; |
| import io.shell.admin.aas._2._0.DataElementsT; |
| import io.shell.admin.aas._2._0._0Package; |
| |
| import java.util.Collection; |
| |
| 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.MinimalEObjectImpl; |
| |
| import org.eclipse.emf.ecore.util.EObjectContainmentEList; |
| import org.eclipse.emf.ecore.util.InternalEList; |
| |
| /** |
| * <!-- begin-user-doc --> |
| * An implementation of the model object '<em><b>Data Elements T</b></em>'. |
| * <!-- end-user-doc --> |
| * <p> |
| * The following features are implemented: |
| * </p> |
| * <ul> |
| * <li>{@link io.shell.admin.aas._2._0.impl.DataElementsTImpl#getDataElement <em>Data Element</em>}</li> |
| * </ul> |
| * |
| * @generated |
| */ |
| public class DataElementsTImpl extends MinimalEObjectImpl.Container implements DataElementsT { |
| /** |
| * The cached value of the '{@link #getDataElement() <em>Data Element</em>}' containment reference list. |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @see #getDataElement() |
| * @generated |
| * @ordered |
| */ |
| protected EList<DataElementAbstractT> dataElement; |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| protected DataElementsTImpl() { |
| super(); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| @Override |
| protected EClass eStaticClass() { |
| return _0Package.Literals.DATA_ELEMENTS_T; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| public EList<DataElementAbstractT> getDataElement() { |
| if (dataElement == null) { |
| dataElement = new EObjectContainmentEList<DataElementAbstractT>(DataElementAbstractT.class, this, _0Package.DATA_ELEMENTS_T__DATA_ELEMENT); |
| } |
| return dataElement; |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| @Override |
| public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { |
| switch (featureID) { |
| case _0Package.DATA_ELEMENTS_T__DATA_ELEMENT: |
| return ((InternalEList<?>)getDataElement()).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 _0Package.DATA_ELEMENTS_T__DATA_ELEMENT: |
| return getDataElement(); |
| } |
| 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 _0Package.DATA_ELEMENTS_T__DATA_ELEMENT: |
| getDataElement().clear(); |
| getDataElement().addAll((Collection<? extends DataElementAbstractT>)newValue); |
| return; |
| } |
| super.eSet(featureID, newValue); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| @Override |
| public void eUnset(int featureID) { |
| switch (featureID) { |
| case _0Package.DATA_ELEMENTS_T__DATA_ELEMENT: |
| getDataElement().clear(); |
| return; |
| } |
| super.eUnset(featureID); |
| } |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| @Override |
| public boolean eIsSet(int featureID) { |
| switch (featureID) { |
| case _0Package.DATA_ELEMENTS_T__DATA_ELEMENT: |
| return dataElement != null && !dataElement.isEmpty(); |
| } |
| return super.eIsSet(featureID); |
| } |
| |
| } //DataElementsTImpl |