/**
*
*
*
* $Id$
*/
package net.opengis.wfs.impl;
import net.opengis.wfs.MetadataURLType;
import net.opengis.wfs.WfsPackage;
import org.eclipse.emf.common.notify.Notification;
import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.ecore.impl.ENotificationImpl;
import org.eclipse.emf.ecore.impl.EObjectImpl;
/**
*
* An implementation of the model object 'Metadata URL Type'.
*
*
* The following features are implemented:
*
* - {@link net.opengis.wfs.impl.MetadataURLTypeImpl#getValue Value}
* - {@link net.opengis.wfs.impl.MetadataURLTypeImpl#getFormat Format}
* - {@link net.opengis.wfs.impl.MetadataURLTypeImpl#getType Type}
*
*
*
* @generated
*/
public class MetadataURLTypeImpl extends EObjectImpl implements MetadataURLType {
/**
* The default value of the '{@link #getValue() Value}' attribute.
*
*
* @see #getValue()
* @generated
* @ordered
*/
protected static final String VALUE_EDEFAULT = null;
/**
* The cached value of the '{@link #getValue() Value}' attribute.
*
*
* @see #getValue()
* @generated
* @ordered
*/
protected String value = VALUE_EDEFAULT;
/**
* The default value of the '{@link #getFormat() Format}' attribute.
*
*
* @see #getFormat()
* @generated
* @ordered
*/
protected static final String FORMAT_EDEFAULT = null;
/**
* The cached value of the '{@link #getFormat() Format}' attribute.
*
*
* @see #getFormat()
* @generated
* @ordered
*/
protected String format = FORMAT_EDEFAULT;
/**
* The default value of the '{@link #getType() Type}' attribute.
*
*
* @see #getType()
* @generated
* @ordered
*/
protected static final String TYPE_EDEFAULT = null;
/**
* The cached value of the '{@link #getType() Type}' attribute.
*
*
* @see #getType()
* @generated
* @ordered
*/
protected String type = TYPE_EDEFAULT;
/**
*
*
* @generated
*/
protected MetadataURLTypeImpl() {
super();
}
/**
*
*
* @generated
*/
protected EClass eStaticClass() {
return WfsPackage.Literals.METADATA_URL_TYPE;
}
/**
*
*
* @generated
*/
public String getValue() {
return value;
}
/**
*
*
* @generated
*/
public void setValue(String newValue) {
String oldValue = value;
value = newValue;
if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, WfsPackage.METADATA_URL_TYPE__VALUE, oldValue, value));
}
/**
*
*
* @generated
*/
public String getFormat() {
return format;
}
/**
*
*
* @generated
*/
public void setFormat(String newFormat) {
String oldFormat = format;
format = newFormat;
if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, WfsPackage.METADATA_URL_TYPE__FORMAT, oldFormat, format));
}
/**
*
*
* @generated
*/
public String getType() {
return type;
}
/**
*
*
* @generated
*/
public void setType(String newType) {
String oldType = type;
type = newType;
if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, WfsPackage.METADATA_URL_TYPE__TYPE, oldType, type));
}
/**
*
*
* @generated
*/
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
case WfsPackage.METADATA_URL_TYPE__VALUE:
return getValue();
case WfsPackage.METADATA_URL_TYPE__FORMAT:
return getFormat();
case WfsPackage.METADATA_URL_TYPE__TYPE:
return getType();
}
return super.eGet(featureID, resolve, coreType);
}
/**
*
*
* @generated
*/
public void eSet(int featureID, Object newValue) {
switch (featureID) {
case WfsPackage.METADATA_URL_TYPE__VALUE:
setValue((String)newValue);
return;
case WfsPackage.METADATA_URL_TYPE__FORMAT:
setFormat((String)newValue);
return;
case WfsPackage.METADATA_URL_TYPE__TYPE:
setType((String)newValue);
return;
}
super.eSet(featureID, newValue);
}
/**
*
*
* @generated
*/
public void eUnset(int featureID) {
switch (featureID) {
case WfsPackage.METADATA_URL_TYPE__VALUE:
setValue(VALUE_EDEFAULT);
return;
case WfsPackage.METADATA_URL_TYPE__FORMAT:
setFormat(FORMAT_EDEFAULT);
return;
case WfsPackage.METADATA_URL_TYPE__TYPE:
setType(TYPE_EDEFAULT);
return;
}
super.eUnset(featureID);
}
/**
*
*
* @generated
*/
public boolean eIsSet(int featureID) {
switch (featureID) {
case WfsPackage.METADATA_URL_TYPE__VALUE:
return VALUE_EDEFAULT == null ? value != null : !VALUE_EDEFAULT.equals(value);
case WfsPackage.METADATA_URL_TYPE__FORMAT:
return FORMAT_EDEFAULT == null ? format != null : !FORMAT_EDEFAULT.equals(format);
case WfsPackage.METADATA_URL_TYPE__TYPE:
return TYPE_EDEFAULT == null ? type != null : !TYPE_EDEFAULT.equals(type);
}
return super.eIsSet(featureID);
}
/**
*
*
* @generated
*/
public String toString() {
if (eIsProxy()) return super.toString();
StringBuffer result = new StringBuffer(super.toString());
result.append(" (value: ");
result.append(value);
result.append(", format: ");
result.append(format);
result.append(", type: ");
result.append(type);
result.append(')');
return result.toString();
}
} //MetadataURLTypeImpl