blob: e805af33b0b0500a41497fb622170e6d10f81fe8 [file] [log] [blame]
/**
* <copyright>
* </copyright>
*
* $Id: GuidanceDescriptionImpl.java,v 1.3 2006/09/07 00:05:59 klow Exp $
*/
package org.eclipse.epf.xml.uma.impl;
import org.eclipse.emf.common.notify.Notification;
import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.ecore.impl.ENotificationImpl;
import org.eclipse.epf.xml.uma.GuidanceDescription;
import org.eclipse.epf.xml.uma.UmaPackage;
/**
* <!-- begin-user-doc -->
* An implementation of the model object '<em><b>Guidance Description</b></em>'.
* <!-- end-user-doc -->
* <p>
* The following features are implemented:
* <ul>
* <li>{@link org.eclipse.epf.xml.uma.impl.GuidanceDescriptionImpl#getAttachment <em>Attachment</em>}</li>
* </ul>
* </p>
*
* @generated
*/
public class GuidanceDescriptionImpl extends ContentDescriptionImpl implements GuidanceDescription {
/**
* The default value of the '{@link #getAttachment() <em>Attachment</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getAttachment()
* @generated
* @ordered
*/
protected static final String ATTACHMENT_EDEFAULT = null;
/**
* The cached value of the '{@link #getAttachment() <em>Attachment</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getAttachment()
* @generated
* @ordered
*/
protected String attachment = ATTACHMENT_EDEFAULT;
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
protected GuidanceDescriptionImpl() {
super();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
protected EClass eStaticClass() {
return UmaPackage.Literals.GUIDANCE_DESCRIPTION;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public String getAttachment() {
return attachment;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public void setAttachment(String newAttachment) {
String oldAttachment = attachment;
attachment = newAttachment;
if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, UmaPackage.GUIDANCE_DESCRIPTION__ATTACHMENT, oldAttachment, attachment));
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
case UmaPackage.GUIDANCE_DESCRIPTION__ATTACHMENT:
return getAttachment();
}
return super.eGet(featureID, resolve, coreType);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public void eSet(int featureID, Object newValue) {
switch (featureID) {
case UmaPackage.GUIDANCE_DESCRIPTION__ATTACHMENT:
setAttachment((String)newValue);
return;
}
super.eSet(featureID, newValue);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public void eUnset(int featureID) {
switch (featureID) {
case UmaPackage.GUIDANCE_DESCRIPTION__ATTACHMENT:
setAttachment(ATTACHMENT_EDEFAULT);
return;
}
super.eUnset(featureID);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public boolean eIsSet(int featureID) {
switch (featureID) {
case UmaPackage.GUIDANCE_DESCRIPTION__ATTACHMENT:
return ATTACHMENT_EDEFAULT == null ? attachment != null : !ATTACHMENT_EDEFAULT.equals(attachment);
}
return super.eIsSet(featureID);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public String toString() {
if (eIsProxy()) return super.toString();
StringBuffer result = new StringBuffer(super.toString());
result.append(" (attachment: ");
result.append(attachment);
result.append(')');
return result.toString();
}
} //GuidanceDescriptionImpl