/**
*
*
*
* $Id$
*/
package net.opengis.fes20.impl;
import net.opengis.fes20.Fes20Package;
import net.opengis.fes20.UpperBoundaryType;
import org.eclipse.emf.common.notify.NotificationChain;
import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.ecore.EObject;
import org.eclipse.emf.ecore.InternalEObject;
import org.eclipse.emf.ecore.impl.EObjectImpl;
import org.eclipse.emf.ecore.util.BasicFeatureMap;
import org.eclipse.emf.ecore.util.FeatureMap;
import org.eclipse.emf.ecore.util.InternalEList;
/**
*
* An implementation of the model object 'Upper Boundary Type'.
*
*
* The following features are implemented:
*
* - {@link net.opengis.fes20.impl.UpperBoundaryTypeImpl#getExpressionGroup Expression Group}
* - {@link net.opengis.fes20.impl.UpperBoundaryTypeImpl#getExpression Expression}
*
*
*
* @generated
*/
public class UpperBoundaryTypeImpl extends EObjectImpl implements UpperBoundaryType {
/**
* The cached value of the '{@link #getExpressionGroup() Expression Group}' attribute list.
*
*
* @see #getExpressionGroup()
* @generated
* @ordered
*/
protected FeatureMap expressionGroup;
/**
*
*
* @generated
*/
protected UpperBoundaryTypeImpl() {
super();
}
/**
*
*
* @generated
*/
@Override
protected EClass eStaticClass() {
return Fes20Package.Literals.UPPER_BOUNDARY_TYPE;
}
/**
*
*
* @generated
*/
public FeatureMap getExpressionGroup() {
if (expressionGroup == null) {
expressionGroup = new BasicFeatureMap(this, Fes20Package.UPPER_BOUNDARY_TYPE__EXPRESSION_GROUP);
}
return expressionGroup;
}
/**
*
*
* @generated
*/
public EObject getExpression() {
return (EObject)getExpressionGroup().get(Fes20Package.Literals.UPPER_BOUNDARY_TYPE__EXPRESSION, true);
}
/**
*
*
* @generated
*/
public NotificationChain basicSetExpression(EObject newExpression, NotificationChain msgs) {
return ((FeatureMap.Internal)getExpressionGroup()).basicAdd(Fes20Package.Literals.UPPER_BOUNDARY_TYPE__EXPRESSION, newExpression, msgs);
}
/**
*
*
* @generated
*/
@Override
public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
switch (featureID) {
case Fes20Package.UPPER_BOUNDARY_TYPE__EXPRESSION_GROUP:
return ((InternalEList>)getExpressionGroup()).basicRemove(otherEnd, msgs);
case Fes20Package.UPPER_BOUNDARY_TYPE__EXPRESSION:
return basicSetExpression(null, msgs);
}
return super.eInverseRemove(otherEnd, featureID, msgs);
}
/**
*
*
* @generated
*/
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
case Fes20Package.UPPER_BOUNDARY_TYPE__EXPRESSION_GROUP:
if (coreType) return getExpressionGroup();
return ((FeatureMap.Internal)getExpressionGroup()).getWrapper();
case Fes20Package.UPPER_BOUNDARY_TYPE__EXPRESSION:
return getExpression();
}
return super.eGet(featureID, resolve, coreType);
}
/**
*
*
* @generated
*/
@Override
public void eSet(int featureID, Object newValue) {
switch (featureID) {
case Fes20Package.UPPER_BOUNDARY_TYPE__EXPRESSION_GROUP:
((FeatureMap.Internal)getExpressionGroup()).set(newValue);
return;
}
super.eSet(featureID, newValue);
}
/**
*
*
* @generated
*/
@Override
public void eUnset(int featureID) {
switch (featureID) {
case Fes20Package.UPPER_BOUNDARY_TYPE__EXPRESSION_GROUP:
getExpressionGroup().clear();
return;
}
super.eUnset(featureID);
}
/**
*
*
* @generated
*/
@Override
public boolean eIsSet(int featureID) {
switch (featureID) {
case Fes20Package.UPPER_BOUNDARY_TYPE__EXPRESSION_GROUP:
return expressionGroup != null && !expressionGroup.isEmpty();
case Fes20Package.UPPER_BOUNDARY_TYPE__EXPRESSION:
return getExpression() != null;
}
return super.eIsSet(featureID);
}
/**
*
*
* @generated
*/
@Override
public String toString() {
if (eIsProxy()) return super.toString();
StringBuffer result = new StringBuffer(super.toString());
result.append(" (expressionGroup: ");
result.append(expressionGroup);
result.append(')');
return result.toString();
}
} //UpperBoundaryTypeImpl