/** */ package hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretationlanguage.partialinterpretation.impl; import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.DefinedElement; import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretationlanguage.partialinterpretation.PartialTypeInterpratation; import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretationlanguage.partialinterpretation.PartialinterpretationPackage; import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretationlanguage.partialinterpretation.Scope; 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.EObjectResolvingEList; import org.eclipse.emf.ecore.util.EObjectWithInverseResolvingEList; import org.eclipse.emf.ecore.util.InternalEList; /** * * An implementation of the model object 'Partial Type Interpratation'. * *

* The following features are implemented: *

* * * @generated */ public abstract class PartialTypeInterpratationImpl extends MinimalEObjectImpl.Container implements PartialTypeInterpratation { /** * The cached value of the '{@link #getElements() Elements}' reference list. * * * @see #getElements() * @generated * @ordered */ protected EList elements; /** * The cached value of the '{@link #getScopes() Scopes}' reference list. * * * @see #getScopes() * @generated * @ordered */ protected EList scopes; /** * * * @generated */ protected PartialTypeInterpratationImpl() { super(); } /** * * * @generated */ @Override protected EClass eStaticClass() { return PartialinterpretationPackage.Literals.PARTIAL_TYPE_INTERPRATATION; } /** * * * @generated */ @Override public EList getElements() { if (elements == null) { elements = new EObjectResolvingEList(DefinedElement.class, this, PartialinterpretationPackage.PARTIAL_TYPE_INTERPRATATION__ELEMENTS); } return elements; } /** * * * @generated */ @Override public EList getScopes() { if (scopes == null) { scopes = new EObjectWithInverseResolvingEList(Scope.class, this, PartialinterpretationPackage.PARTIAL_TYPE_INTERPRATATION__SCOPES, PartialinterpretationPackage.SCOPE__TARGET_TYPE_INTERPRETATION); } return scopes; } /** * * * @generated */ @SuppressWarnings("unchecked") @Override public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { switch (featureID) { case PartialinterpretationPackage.PARTIAL_TYPE_INTERPRATATION__SCOPES: return ((InternalEList)(InternalEList)getScopes()).basicAdd(otherEnd, msgs); } return super.eInverseAdd(otherEnd, featureID, msgs); } /** * * * @generated */ @Override public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { switch (featureID) { case PartialinterpretationPackage.PARTIAL_TYPE_INTERPRATATION__SCOPES: return ((InternalEList)getScopes()).basicRemove(otherEnd, msgs); } return super.eInverseRemove(otherEnd, featureID, msgs); } /** * * * @generated */ @Override public Object eGet(int featureID, boolean resolve, boolean coreType) { switch (featureID) { case PartialinterpretationPackage.PARTIAL_TYPE_INTERPRATATION__ELEMENTS: return getElements(); case PartialinterpretationPackage.PARTIAL_TYPE_INTERPRATATION__SCOPES: return getScopes(); } return super.eGet(featureID, resolve, coreType); } /** * * * @generated */ @SuppressWarnings("unchecked") @Override public void eSet(int featureID, Object newValue) { switch (featureID) { case PartialinterpretationPackage.PARTIAL_TYPE_INTERPRATATION__ELEMENTS: getElements().clear(); getElements().addAll((Collection)newValue); return; case PartialinterpretationPackage.PARTIAL_TYPE_INTERPRATATION__SCOPES: getScopes().clear(); getScopes().addAll((Collection)newValue); return; } super.eSet(featureID, newValue); } /** * * * @generated */ @Override public void eUnset(int featureID) { switch (featureID) { case PartialinterpretationPackage.PARTIAL_TYPE_INTERPRATATION__ELEMENTS: getElements().clear(); return; case PartialinterpretationPackage.PARTIAL_TYPE_INTERPRATATION__SCOPES: getScopes().clear(); return; } super.eUnset(featureID); } /** * * * @generated */ @Override public boolean eIsSet(int featureID) { switch (featureID) { case PartialinterpretationPackage.PARTIAL_TYPE_INTERPRATATION__ELEMENTS: return elements != null && !elements.isEmpty(); case PartialinterpretationPackage.PARTIAL_TYPE_INTERPRATATION__SCOPES: return scopes != null && !scopes.isEmpty(); } return super.eIsSet(featureID); } } //PartialTypeInterpratationImpl