/**
*
*
*
* $Id$
*/
package net.opengis.ows11.impl;
import java.util.Collection;
import net.opengis.ows11.IdentificationType;
import net.opengis.ows11.Ows11Package;
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.util.BasicFeatureMap;
import org.eclipse.emf.ecore.util.EDataTypeEList;
import org.eclipse.emf.ecore.util.FeatureMap;
import org.eclipse.emf.ecore.util.InternalEList;
/**
*
* An implementation of the model object 'Identification Type'.
*
*
* The following features are implemented:
*
* - {@link net.opengis.ows11.impl.IdentificationTypeImpl#getBoundingBoxGroup Bounding Box Group}
* - {@link net.opengis.ows11.impl.IdentificationTypeImpl#getBoundingBox Bounding Box}
* - {@link net.opengis.ows11.impl.IdentificationTypeImpl#getOutputFormat Output Format}
* - {@link net.opengis.ows11.impl.IdentificationTypeImpl#getAvailableCRSGroup Available CRS Group}
* - {@link net.opengis.ows11.impl.IdentificationTypeImpl#getAvailableCRS Available CRS}
*
*
*
* @generated
*/
public class IdentificationTypeImpl extends BasicIdentificationTypeImpl implements IdentificationType {
/**
* The cached value of the '{@link #getBoundingBoxGroup() Bounding Box Group}' attribute list.
*
*
* @see #getBoundingBoxGroup()
* @generated
* @ordered
*/
protected FeatureMap boundingBoxGroup;
/**
* The cached value of the '{@link #getOutputFormat() Output Format}' attribute list.
*
*
* @see #getOutputFormat()
* @generated
* @ordered
*/
protected EList outputFormat;
/**
* The cached value of the '{@link #getAvailableCRSGroup() Available CRS Group}' attribute list.
*
*
* @see #getAvailableCRSGroup()
* @generated
* @ordered
*/
protected FeatureMap availableCRSGroup;
/**
*
*
* @generated
*/
protected IdentificationTypeImpl() {
super();
}
/**
*
*
* @generated
*/
protected EClass eStaticClass() {
return Ows11Package.Literals.IDENTIFICATION_TYPE;
}
/**
*
*
* @generated
*/
public FeatureMap getBoundingBoxGroup() {
if (boundingBoxGroup == null) {
boundingBoxGroup = new BasicFeatureMap(this, Ows11Package.IDENTIFICATION_TYPE__BOUNDING_BOX_GROUP);
}
return boundingBoxGroup;
}
/**
*
*
* @generated
*/
public EList getBoundingBox() {
return getBoundingBoxGroup().list(Ows11Package.Literals.IDENTIFICATION_TYPE__BOUNDING_BOX);
}
/**
*
*
* @generated
*/
public EList getOutputFormat() {
if (outputFormat == null) {
outputFormat = new EDataTypeEList(String.class, this, Ows11Package.IDENTIFICATION_TYPE__OUTPUT_FORMAT);
}
return outputFormat;
}
/**
*
*
* @generated
*/
public FeatureMap getAvailableCRSGroup() {
if (availableCRSGroup == null) {
availableCRSGroup = new BasicFeatureMap(this, Ows11Package.IDENTIFICATION_TYPE__AVAILABLE_CRS_GROUP);
}
return availableCRSGroup;
}
/**
*
*
* @generated
*/
public EList getAvailableCRS() {
return getAvailableCRSGroup().list(Ows11Package.Literals.IDENTIFICATION_TYPE__AVAILABLE_CRS);
}
/**
*
*
* @generated
*/
public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
switch (featureID) {
case Ows11Package.IDENTIFICATION_TYPE__BOUNDING_BOX_GROUP:
return ((InternalEList)getBoundingBoxGroup()).basicRemove(otherEnd, msgs);
case Ows11Package.IDENTIFICATION_TYPE__BOUNDING_BOX:
return ((InternalEList)getBoundingBox()).basicRemove(otherEnd, msgs);
case Ows11Package.IDENTIFICATION_TYPE__AVAILABLE_CRS_GROUP:
return ((InternalEList)getAvailableCRSGroup()).basicRemove(otherEnd, msgs);
}
return super.eInverseRemove(otherEnd, featureID, msgs);
}
/**
*
*
* @generated
*/
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
case Ows11Package.IDENTIFICATION_TYPE__BOUNDING_BOX_GROUP:
if (coreType) return getBoundingBoxGroup();
return ((FeatureMap.Internal)getBoundingBoxGroup()).getWrapper();
case Ows11Package.IDENTIFICATION_TYPE__BOUNDING_BOX:
return getBoundingBox();
case Ows11Package.IDENTIFICATION_TYPE__OUTPUT_FORMAT:
return getOutputFormat();
case Ows11Package.IDENTIFICATION_TYPE__AVAILABLE_CRS_GROUP:
if (coreType) return getAvailableCRSGroup();
return ((FeatureMap.Internal)getAvailableCRSGroup()).getWrapper();
case Ows11Package.IDENTIFICATION_TYPE__AVAILABLE_CRS:
return getAvailableCRS();
}
return super.eGet(featureID, resolve, coreType);
}
/**
*
*
* @generated
*/
public void eSet(int featureID, Object newValue) {
switch (featureID) {
case Ows11Package.IDENTIFICATION_TYPE__BOUNDING_BOX_GROUP:
((FeatureMap.Internal)getBoundingBoxGroup()).set(newValue);
return;
case Ows11Package.IDENTIFICATION_TYPE__BOUNDING_BOX:
getBoundingBox().clear();
getBoundingBox().addAll((Collection)newValue);
return;
case Ows11Package.IDENTIFICATION_TYPE__OUTPUT_FORMAT:
getOutputFormat().clear();
getOutputFormat().addAll((Collection)newValue);
return;
case Ows11Package.IDENTIFICATION_TYPE__AVAILABLE_CRS_GROUP:
((FeatureMap.Internal)getAvailableCRSGroup()).set(newValue);
return;
case Ows11Package.IDENTIFICATION_TYPE__AVAILABLE_CRS:
getAvailableCRS().clear();
getAvailableCRS().addAll((Collection)newValue);
return;
}
super.eSet(featureID, newValue);
}
/**
*
*
* @generated
*/
public void eUnset(int featureID) {
switch (featureID) {
case Ows11Package.IDENTIFICATION_TYPE__BOUNDING_BOX_GROUP:
getBoundingBoxGroup().clear();
return;
case Ows11Package.IDENTIFICATION_TYPE__BOUNDING_BOX:
getBoundingBox().clear();
return;
case Ows11Package.IDENTIFICATION_TYPE__OUTPUT_FORMAT:
getOutputFormat().clear();
return;
case Ows11Package.IDENTIFICATION_TYPE__AVAILABLE_CRS_GROUP:
getAvailableCRSGroup().clear();
return;
case Ows11Package.IDENTIFICATION_TYPE__AVAILABLE_CRS:
getAvailableCRS().clear();
return;
}
super.eUnset(featureID);
}
/**
*
*
* @generated
*/
public boolean eIsSet(int featureID) {
switch (featureID) {
case Ows11Package.IDENTIFICATION_TYPE__BOUNDING_BOX_GROUP:
return boundingBoxGroup != null && !boundingBoxGroup.isEmpty();
case Ows11Package.IDENTIFICATION_TYPE__BOUNDING_BOX:
return !getBoundingBox().isEmpty();
case Ows11Package.IDENTIFICATION_TYPE__OUTPUT_FORMAT:
return outputFormat != null && !outputFormat.isEmpty();
case Ows11Package.IDENTIFICATION_TYPE__AVAILABLE_CRS_GROUP:
return availableCRSGroup != null && !availableCRSGroup.isEmpty();
case Ows11Package.IDENTIFICATION_TYPE__AVAILABLE_CRS:
return !getAvailableCRS().isEmpty();
}
return super.eIsSet(featureID);
}
/**
*
*
* @generated
*/
public String toString() {
if (eIsProxy()) return super.toString();
StringBuffer result = new StringBuffer(super.toString());
result.append(" (boundingBoxGroup: ");
result.append(boundingBoxGroup);
result.append(", outputFormat: ");
result.append(outputFormat);
result.append(", availableCRSGroup: ");
result.append(availableCRSGroup);
result.append(')');
return result.toString();
}
} //IdentificationTypeImpl