code: /**
   */
  package IFML.Mobile.impl;
  
  import IFML.Mobile.Microphone;
  import IFML.Mobile.MobilePackage;
  
  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>Microphone</b></em>'.
   * <!-- end-user-doc -->
   * <p>
   * The following features are implemented:
   * <ul>
   *   <li>{@link IFML.Mobile.impl.MicrophoneImpl#isIsAvailable <em>Is Available</em>}</li>
   * </ul>
   * </p>
   *
   * @generated
   */
  public class MicrophoneImpl extends MobileDeviceSensorImpl implements Microphone {
  	/**
  	 * The default value of the '{@link #isIsAvailable() <em>Is Available</em>}' attribute.
  	 * <!-- begin-user-doc -->
  	 * <!-- end-user-doc -->
  	 * @see #isIsAvailable()
  	 * @generated
  	 * @ordered
  	 */
  	protected static final boolean IS_AVAILABLE_EDEFAULT = false;
  
  	/**
  	 * The cached value of the '{@link #isIsAvailable() <em>Is Available</em>}' attribute.
  	 * <!-- begin-user-doc -->
  	 * <!-- end-user-doc -->
  	 * @see #isIsAvailable()
  	 * @generated
  	 * @ordered
  	 */
  	protected boolean isAvailable = IS_AVAILABLE_EDEFAULT;
  
  	/**
  	 * <!-- begin-user-doc -->
  	 * <!-- end-user-doc -->
  	 * @generated
  	 */
  	protected MicrophoneImpl() {
  		super();
  	}
  
  	/**
  	 * <!-- begin-user-doc -->
  	 * <!-- end-user-doc -->
  	 * @generated
  	 */
  	@Override
  	protected EClass eStaticClass() {
  		return MobilePackage.Literals.MICROPHONE;
  	}
  
  	/**
  	 * <!-- begin-user-doc -->
  	 * <!-- end-user-doc -->
  	 * @generated
  	 */
  	public boolean isIsAvailable() {
  		return isAvailable;
  	}
  
  	/**
  	 * <!-- begin-user-doc -->
  	 * <!-- end-user-doc -->
  	 * @generated
  	 */
  	public void setIsAvailable(boolean newIsAvailable) {
  		boolean oldIsAvailable = isAvailable;
  		isAvailable = newIsAvailable;
  		if (eNotificationRequired())
  			eNotify(new ENotificationImpl(this, Notification.SET, MobilePackage.MICROPHONE__IS_AVAILABLE, oldIsAvailable, isAvailable));
  	}
  
  	/**
  	 * <!-- begin-user-doc -->
  	 * <!-- end-user-doc -->
  	 * @generated
  	 */
  	@Override
  	public Object eGet(int featureID, boolean resolve, boolean coreType) {
  		switch (featureID) {
  			case MobilePackage.MICROPHONE__IS_AVAILABLE:
  				return isIsAvailable();
  		}
  		return super.eGet(featureID, resolve, coreType);
  	}
  
  	/**
  	 * <!-- begin-user-doc -->
  	 * <!-- end-user-doc -->
  	 * @generated
  	 */
  	@Override
  	public void eSet(int featureID, Object newValue) {
  		switch (featureID) {
  			case MobilePackage.MICROPHONE__IS_AVAILABLE:
  				setIsAvailable((Boolean)newValue);
  				return;
  		}
  		super.eSet(featureID, newValue);
  	}
  
  	/**
  	 * <!-- begin-user-doc -->
  	 * <!-- end-user-doc -->
  	 * @generated
  	 */
  	@Override
  	public void eUnset(int featureID) {
  		switch (featureID) {
  			case MobilePackage.MICROPHONE__IS_AVAILABLE:
  				setIsAvailable(IS_AVAILABLE_EDEFAULT);
  				return;
  		}
  		super.eUnset(featureID);
  	}
  
  	/**
  	 * <!-- begin-user-doc -->
  	 * <!-- end-user-doc -->
  	 * @generated
  	 */
  	@Override
  	public boolean eIsSet(int featureID) {
  		switch (featureID) {
  			case MobilePackage.MICROPHONE__IS_AVAILABLE:
  				return isAvailable != IS_AVAILABLE_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(" (isAvailable: ");
  		result.append(isAvailable);
  		result.append(')');
  		return result.toString();
  	}
  
  } //MicrophoneImpl
  