jtl-eclipse-master/JTL.emftext.ASP/src-gen/ASP/impl/EdgeImpl.java
/**
 */
package ASP.impl;

import ASP.ASPPackage;
import ASP.Edge;

import org.eclipse.emf.common.notify.Notification;

import org.eclipse.emf.ecore.EClass;

import org.eclipse.emf.ecore.impl.ENotificationImpl;

/**
 * <!-- begin-user-doc -->
 * An implementation of the model object '<em><b>Edge</b></em>'.
 * <!-- end-user-doc -->
 * <p>
 * The following features are implemented:
 * </p>
 * <ul>
 *   <li>{@link ASP.impl.EdgeImpl#isIsEdgex <em>Is Edgex</em>}</li>
 * </ul>
 *
 * @generated
 */
public class EdgeImpl extends FunctionImpl implements Edge {
	/**
	 * The default value of the '{@link #isIsEdgex() <em>Is Edgex</em>}' attribute.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @see #isIsEdgex()
	 * @generated
	 * @ordered
	 */
	protected static final boolean IS_EDGEX_EDEFAULT = false;

	/**
	 * The cached value of the '{@link #isIsEdgex() <em>Is Edgex</em>}' attribute.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @see #isIsEdgex()
	 * @generated
	 * @ordered
	 */
	protected boolean isEdgex = IS_EDGEX_EDEFAULT;

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	protected EdgeImpl() {
		super();
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	@Override
	protected EClass eStaticClass() {
		return ASPPackage.Literals.EDGE;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean isIsEdgex() {
		return isEdgex;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public void setIsEdgex(boolean newIsEdgex) {
		boolean oldIsEdgex = isEdgex;
		isEdgex = newIsEdgex;
		if (eNotificationRequired())
			eNotify(new ENotificationImpl(this, Notification.SET, ASPPackage.EDGE__IS_EDGEX, oldIsEdgex, isEdgex));
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	@Override
	public Object eGet(int featureID, boolean resolve, boolean coreType) {
		switch (featureID) {
			case ASPPackage.EDGE__IS_EDGEX:
				return isIsEdgex();
		}
		return super.eGet(featureID, resolve, coreType);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	@Override
	public void eSet(int featureID, Object newValue) {
		switch (featureID) {
			case ASPPackage.EDGE__IS_EDGEX:
				setIsEdgex((Boolean)newValue);
				return;
		}
		super.eSet(featureID, newValue);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	@Override
	public void eUnset(int featureID) {
		switch (featureID) {
			case ASPPackage.EDGE__IS_EDGEX:
				setIsEdgex(IS_EDGEX_EDEFAULT);
				return;
		}
		super.eUnset(featureID);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	@Override
	public boolean eIsSet(int featureID) {
		switch (featureID) {
			case ASPPackage.EDGE__IS_EDGEX:
				return isEdgex != IS_EDGEX_EDEFAULT;
		}
		return super.eIsSet(featureID);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	@Override
	public String toString() {
		if (eIsProxy()) return super.toString();

		StringBuffer result = new StringBuffer(super.toString());
		result.append(" (isEdgex: ");
		result.append(isEdgex);
		result.append(')');
		return result.toString();
	}

} //EdgeImpl
