All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.nasdanika.models.party.impl.PhoneImpl Maven / Gradle / Ivy

/**
 */
package org.nasdanika.models.party.impl;

import org.eclipse.emf.ecore.EClass;

import org.nasdanika.models.party.PartyPackage;
import org.nasdanika.models.party.Phone;

/**
 * 
 * An implementation of the model object 'Phone'.
 * 
 * 

* The following features are implemented: *

*
    *
  • {@link org.nasdanika.models.party.impl.PhoneImpl#getCountryCode Country Code}
  • *
  • {@link org.nasdanika.models.party.impl.PhoneImpl#getAreaCode Area Code}
  • *
  • {@link org.nasdanika.models.party.impl.PhoneImpl#getPhoneNumber Phone Number}
  • *
  • {@link org.nasdanika.models.party.impl.PhoneImpl#getExtension Extension}
  • *
* * @generated */ public class PhoneImpl extends ContactMethodImpl implements Phone { /** * The default value of the '{@link #getCountryCode() Country Code}' attribute. * * * @see #getCountryCode() * @generated * @ordered */ protected static final int COUNTRY_CODE_EDEFAULT = 0; /** * The default value of the '{@link #getAreaCode() Area Code}' attribute. * * * @see #getAreaCode() * @generated * @ordered */ protected static final int AREA_CODE_EDEFAULT = 0; /** * The default value of the '{@link #getPhoneNumber() Phone Number}' attribute. * * * @see #getPhoneNumber() * @generated * @ordered */ protected static final int PHONE_NUMBER_EDEFAULT = 0; /** * The default value of the '{@link #getExtension() Extension}' attribute. * * * @see #getExtension() * @generated * @ordered */ protected static final int EXTENSION_EDEFAULT = 0; /** * * * @generated */ protected PhoneImpl() { super(); } /** * * * @generated */ @Override protected EClass eStaticClass() { return PartyPackage.Literals.PHONE; } /** * * * @generated */ @Override public int getCountryCode() { return (Integer)eDynamicGet(PartyPackage.PHONE__COUNTRY_CODE, PartyPackage.Literals.PHONE__COUNTRY_CODE, true, true); } /** * * * @generated */ @Override public void setCountryCode(int newCountryCode) { eDynamicSet(PartyPackage.PHONE__COUNTRY_CODE, PartyPackage.Literals.PHONE__COUNTRY_CODE, newCountryCode); } /** * * * @generated */ @Override public int getAreaCode() { return (Integer)eDynamicGet(PartyPackage.PHONE__AREA_CODE, PartyPackage.Literals.PHONE__AREA_CODE, true, true); } /** * * * @generated */ @Override public void setAreaCode(int newAreaCode) { eDynamicSet(PartyPackage.PHONE__AREA_CODE, PartyPackage.Literals.PHONE__AREA_CODE, newAreaCode); } /** * * * @generated */ @Override public int getPhoneNumber() { return (Integer)eDynamicGet(PartyPackage.PHONE__PHONE_NUMBER, PartyPackage.Literals.PHONE__PHONE_NUMBER, true, true); } /** * * * @generated */ @Override public void setPhoneNumber(int newPhoneNumber) { eDynamicSet(PartyPackage.PHONE__PHONE_NUMBER, PartyPackage.Literals.PHONE__PHONE_NUMBER, newPhoneNumber); } /** * * * @generated */ @Override public int getExtension() { return (Integer)eDynamicGet(PartyPackage.PHONE__EXTENSION, PartyPackage.Literals.PHONE__EXTENSION, true, true); } /** * * * @generated */ @Override public void setExtension(int newExtension) { eDynamicSet(PartyPackage.PHONE__EXTENSION, PartyPackage.Literals.PHONE__EXTENSION, newExtension); } /** * * * @generated */ @Override public Object eGet(int featureID, boolean resolve, boolean coreType) { switch (featureID) { case PartyPackage.PHONE__COUNTRY_CODE: return getCountryCode(); case PartyPackage.PHONE__AREA_CODE: return getAreaCode(); case PartyPackage.PHONE__PHONE_NUMBER: return getPhoneNumber(); case PartyPackage.PHONE__EXTENSION: return getExtension(); } return super.eGet(featureID, resolve, coreType); } /** * * * @generated */ @Override public void eSet(int featureID, Object newValue) { switch (featureID) { case PartyPackage.PHONE__COUNTRY_CODE: setCountryCode((Integer)newValue); return; case PartyPackage.PHONE__AREA_CODE: setAreaCode((Integer)newValue); return; case PartyPackage.PHONE__PHONE_NUMBER: setPhoneNumber((Integer)newValue); return; case PartyPackage.PHONE__EXTENSION: setExtension((Integer)newValue); return; } super.eSet(featureID, newValue); } /** * * * @generated */ @Override public void eUnset(int featureID) { switch (featureID) { case PartyPackage.PHONE__COUNTRY_CODE: setCountryCode(COUNTRY_CODE_EDEFAULT); return; case PartyPackage.PHONE__AREA_CODE: setAreaCode(AREA_CODE_EDEFAULT); return; case PartyPackage.PHONE__PHONE_NUMBER: setPhoneNumber(PHONE_NUMBER_EDEFAULT); return; case PartyPackage.PHONE__EXTENSION: setExtension(EXTENSION_EDEFAULT); return; } super.eUnset(featureID); } /** * * * @generated */ @Override public boolean eIsSet(int featureID) { switch (featureID) { case PartyPackage.PHONE__COUNTRY_CODE: return getCountryCode() != COUNTRY_CODE_EDEFAULT; case PartyPackage.PHONE__AREA_CODE: return getAreaCode() != AREA_CODE_EDEFAULT; case PartyPackage.PHONE__PHONE_NUMBER: return getPhoneNumber() != PHONE_NUMBER_EDEFAULT; case PartyPackage.PHONE__EXTENSION: return getExtension() != EXTENSION_EDEFAULT; } return super.eIsSet(featureID); } } //PhoneImpl




© 2015 - 2024 Weber Informatics LLC | Privacy Policy