/** */ package de.hftstuttgart.buildingphysics.impl; import de.hftstuttgart.buildingphysics.BuildingPhysicsPackage; import de.hftstuttgart.buildingphysics.WindowType; import de.hftstuttgart.cityunits.model.NullableQuantity; import de.hftstuttgart.cityunits.model.quantities.QuantitiesFactory; import de.hftstuttgart.cityunits.model.quantities.QuantitiesPackage; 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.MinimalEObjectImpl; /** * * An implementation of the model object 'Window Type'. * *

* The following features are implemented: *

* * * @generated */ public class WindowTypeImpl extends MinimalEObjectImpl.Container implements WindowType { /** * The default value of the '{@link #getWindowTypeId() Window Type Id}' attribute. * * * @see #getWindowTypeId() * @generated * @ordered */ protected static final String WINDOW_TYPE_ID_EDEFAULT = null; /** * The cached value of the '{@link #getWindowTypeId() Window Type Id}' attribute. * * * @see #getWindowTypeId() * @generated * @ordered */ protected String windowTypeId = WINDOW_TYPE_ID_EDEFAULT; /** * The default value of the '{@link #getName() Name}' attribute. * * * @see #getName() * @generated * @ordered */ protected static final String NAME_EDEFAULT = null; /** * The cached value of the '{@link #getName() Name}' attribute. * * * @see #getName() * @generated * @ordered */ protected String name = NAME_EDEFAULT; /** * The default value of the '{@link #getUValue() UValue}' attribute. * * * @see #getUValue() * @generated * @ordered */ protected static final NullableQuantity UVALUE_EDEFAULT = (NullableQuantity) QuantitiesFactory.eINSTANCE .createFromString(QuantitiesPackage.eINSTANCE.getQuantityDouble(), "W/(m\u00b2*K)"); /** * The cached value of the '{@link #getUValue() UValue}' attribute. * * * @see #getUValue() * @generated * @ordered */ protected NullableQuantity uValue = UVALUE_EDEFAULT; /** * The default value of the '{@link #getGValue() GValue}' attribute. * * * @see #getGValue() * @generated * @ordered */ protected static final double GVALUE_EDEFAULT = 0.0; /** * The cached value of the '{@link #getGValue() GValue}' attribute. * * * @see #getGValue() * @generated * @ordered */ protected double gValue = GVALUE_EDEFAULT; /** * The default value of the '{@link #getGlazingNumber() Glazing Number}' attribute. * * * @see #getGlazingNumber() * @generated * @ordered */ protected static final int GLAZING_NUMBER_EDEFAULT = 1; /** * The cached value of the '{@link #getGlazingNumber() Glazing Number}' attribute. * * * @see #getGlazingNumber() * @generated * @ordered */ protected int glazingNumber = GLAZING_NUMBER_EDEFAULT; /** * The default value of the '{@link #getFrameRatio() Frame Ratio}' attribute. * * * @see #getFrameRatio() * @generated * @ordered */ protected static final Double FRAME_RATIO_EDEFAULT = null; /** * The cached value of the '{@link #getFrameRatio() Frame Ratio}' attribute. * * * @see #getFrameRatio() * @generated * @ordered */ protected Double frameRatio = FRAME_RATIO_EDEFAULT; /** * The default value of the '{@link #getEmbodiedEnergy() Embodied Energy}' attribute. * * * @see #getEmbodiedEnergy() * @generated * @ordered */ protected static final NullableQuantity EMBODIED_ENERGY_EDEFAULT = (NullableQuantity) QuantitiesFactory.eINSTANCE .createFromString(QuantitiesPackage.eINSTANCE.getQuantityDouble(), "kW*h/m\u00b2"); /** * The cached value of the '{@link #getEmbodiedEnergy() Embodied Energy}' attribute. * * * @see #getEmbodiedEnergy() * @generated * @ordered */ protected NullableQuantity embodiedEnergy = EMBODIED_ENERGY_EDEFAULT; /** * The default value of the '{@link #getEmbodiedCarbon() Embodied Carbon}' attribute. * * * @see #getEmbodiedCarbon() * @generated * @ordered */ protected static final NullableQuantity EMBODIED_CARBON_EDEFAULT = (NullableQuantity) QuantitiesFactory.eINSTANCE .createFromString(QuantitiesPackage.eINSTANCE.getQuantityDouble(), "kg"); /** * The cached value of the '{@link #getEmbodiedCarbon() Embodied Carbon}' attribute. * * * @see #getEmbodiedCarbon() * @generated * @ordered */ protected NullableQuantity embodiedCarbon = EMBODIED_CARBON_EDEFAULT; /** * The default value of the '{@link #getConstructionDescription() Construction Description}' attribute. * * * @see #getConstructionDescription() * @generated * @ordered */ protected static final String CONSTRUCTION_DESCRIPTION_EDEFAULT = null; /** * The cached value of the '{@link #getConstructionDescription() Construction Description}' attribute. * * * @see #getConstructionDescription() * @generated * @ordered */ protected String constructionDescription = CONSTRUCTION_DESCRIPTION_EDEFAULT; /** * The default value of the '{@link #getDisposalEnergy() Disposal Energy}' attribute. * * * @see #getDisposalEnergy() * @generated * @ordered */ protected static final NullableQuantity DISPOSAL_ENERGY_EDEFAULT = (NullableQuantity) QuantitiesFactory.eINSTANCE .createFromString(QuantitiesPackage.eINSTANCE.getQuantityDouble(), "kW*h/m\u00b2"); /** * The cached value of the '{@link #getDisposalEnergy() Disposal Energy}' attribute. * * * @see #getDisposalEnergy() * @generated * @ordered */ protected NullableQuantity disposalEnergy = DISPOSAL_ENERGY_EDEFAULT; /** * The default value of the '{@link #getDisposalCarbon() Disposal Carbon}' attribute. * * * @see #getDisposalCarbon() * @generated * @ordered */ protected static final NullableQuantity DISPOSAL_CARBON_EDEFAULT = (NullableQuantity) QuantitiesFactory.eINSTANCE .createFromString(QuantitiesPackage.eINSTANCE.getQuantityDouble(), "kg"); /** * The cached value of the '{@link #getDisposalCarbon() Disposal Carbon}' attribute. * * * @see #getDisposalCarbon() * @generated * @ordered */ protected NullableQuantity disposalCarbon = DISPOSAL_CARBON_EDEFAULT; /** * The default value of the '{@link #getDisposalDescription() Disposal Description}' attribute. * * * @see #getDisposalDescription() * @generated * @ordered */ protected static final String DISPOSAL_DESCRIPTION_EDEFAULT = null; /** * The cached value of the '{@link #getDisposalDescription() Disposal Description}' attribute. * * * @see #getDisposalDescription() * @generated * @ordered */ protected String disposalDescription = DISPOSAL_DESCRIPTION_EDEFAULT; /** * * * @generated */ protected WindowTypeImpl() { super(); } /** * * * @generated */ @Override protected EClass eStaticClass() { return BuildingPhysicsPackage.Literals.WINDOW_TYPE; } /** * * * @generated */ @Override public String getWindowTypeId() { return windowTypeId; } /** * * * @generated */ @Override public void setWindowTypeId(String newWindowTypeId) { String oldWindowTypeId = windowTypeId; windowTypeId = newWindowTypeId; if (eNotificationRequired()) eNotify(new ENotificationImpl(this, Notification.SET, BuildingPhysicsPackage.WINDOW_TYPE__WINDOW_TYPE_ID, oldWindowTypeId, windowTypeId)); } /** * * * @generated */ @Override public String getName() { return name; } /** * * * @generated */ @Override public void setName(String newName) { String oldName = name; name = newName; if (eNotificationRequired()) eNotify(new ENotificationImpl(this, Notification.SET, BuildingPhysicsPackage.WINDOW_TYPE__NAME, oldName, name)); } /** * * * @generated */ @Override public NullableQuantity getUValue() { return uValue; } /** * * * @generated */ @Override public void setUValue(NullableQuantity newUValue) { NullableQuantity oldUValue = uValue; uValue = newUValue; if (eNotificationRequired()) eNotify(new ENotificationImpl(this, Notification.SET, BuildingPhysicsPackage.WINDOW_TYPE__UVALUE, oldUValue, uValue)); } /** * * * @generated */ @Override public double getGValue() { return gValue; } /** * * * @generated */ @Override public void setGValue(double newGValue) { double oldGValue = gValue; gValue = newGValue; if (eNotificationRequired()) eNotify(new ENotificationImpl(this, Notification.SET, BuildingPhysicsPackage.WINDOW_TYPE__GVALUE, oldGValue, gValue)); } /** * * * @generated */ @Override public int getGlazingNumber() { return glazingNumber; } /** * * * @generated */ @Override public void setGlazingNumber(int newGlazingNumber) { int oldGlazingNumber = glazingNumber; glazingNumber = newGlazingNumber; if (eNotificationRequired()) eNotify(new ENotificationImpl(this, Notification.SET, BuildingPhysicsPackage.WINDOW_TYPE__GLAZING_NUMBER, oldGlazingNumber, glazingNumber)); } /** * * * @generated */ @Override public Double getFrameRatio() { return frameRatio; } /** * * * @generated */ @Override public void setFrameRatio(Double newFrameRatio) { Double oldFrameRatio = frameRatio; frameRatio = newFrameRatio; if (eNotificationRequired()) eNotify(new ENotificationImpl(this, Notification.SET, BuildingPhysicsPackage.WINDOW_TYPE__FRAME_RATIO, oldFrameRatio, frameRatio)); } /** * * * @generated */ @Override public NullableQuantity getEmbodiedEnergy() { return embodiedEnergy; } /** * * * @generated */ @Override public void setEmbodiedEnergy(NullableQuantity newEmbodiedEnergy) { NullableQuantity oldEmbodiedEnergy = embodiedEnergy; embodiedEnergy = newEmbodiedEnergy; if (eNotificationRequired()) eNotify(new ENotificationImpl(this, Notification.SET, BuildingPhysicsPackage.WINDOW_TYPE__EMBODIED_ENERGY, oldEmbodiedEnergy, embodiedEnergy)); } /** * * * @generated */ @Override public NullableQuantity getEmbodiedCarbon() { return embodiedCarbon; } /** * * * @generated */ @Override public void setEmbodiedCarbon(NullableQuantity newEmbodiedCarbon) { NullableQuantity oldEmbodiedCarbon = embodiedCarbon; embodiedCarbon = newEmbodiedCarbon; if (eNotificationRequired()) eNotify(new ENotificationImpl(this, Notification.SET, BuildingPhysicsPackage.WINDOW_TYPE__EMBODIED_CARBON, oldEmbodiedCarbon, embodiedCarbon)); } /** * * * @generated */ @Override public String getConstructionDescription() { return constructionDescription; } /** * * * @generated */ @Override public void setConstructionDescription(String newConstructionDescription) { String oldConstructionDescription = constructionDescription; constructionDescription = newConstructionDescription; if (eNotificationRequired()) eNotify(new ENotificationImpl(this, Notification.SET, BuildingPhysicsPackage.WINDOW_TYPE__CONSTRUCTION_DESCRIPTION, oldConstructionDescription, constructionDescription)); } /** * * * @generated */ @Override public NullableQuantity getDisposalEnergy() { return disposalEnergy; } /** * * * @generated */ @Override public void setDisposalEnergy(NullableQuantity newDisposalEnergy) { NullableQuantity oldDisposalEnergy = disposalEnergy; disposalEnergy = newDisposalEnergy; if (eNotificationRequired()) eNotify(new ENotificationImpl(this, Notification.SET, BuildingPhysicsPackage.WINDOW_TYPE__DISPOSAL_ENERGY, oldDisposalEnergy, disposalEnergy)); } /** * * * @generated */ @Override public NullableQuantity getDisposalCarbon() { return disposalCarbon; } /** * * * @generated */ @Override public void setDisposalCarbon(NullableQuantity newDisposalCarbon) { NullableQuantity oldDisposalCarbon = disposalCarbon; disposalCarbon = newDisposalCarbon; if (eNotificationRequired()) eNotify(new ENotificationImpl(this, Notification.SET, BuildingPhysicsPackage.WINDOW_TYPE__DISPOSAL_CARBON, oldDisposalCarbon, disposalCarbon)); } /** * * * @generated */ @Override public String getDisposalDescription() { return disposalDescription; } /** * * * @generated */ @Override public void setDisposalDescription(String newDisposalDescription) { String oldDisposalDescription = disposalDescription; disposalDescription = newDisposalDescription; if (eNotificationRequired()) eNotify(new ENotificationImpl(this, Notification.SET, BuildingPhysicsPackage.WINDOW_TYPE__DISPOSAL_DESCRIPTION, oldDisposalDescription, disposalDescription)); } /** * * * @generated */ @Override public Object eGet(int featureID, boolean resolve, boolean coreType) { switch (featureID) { case BuildingPhysicsPackage.WINDOW_TYPE__WINDOW_TYPE_ID: return getWindowTypeId(); case BuildingPhysicsPackage.WINDOW_TYPE__NAME: return getName(); case BuildingPhysicsPackage.WINDOW_TYPE__UVALUE: return getUValue(); case BuildingPhysicsPackage.WINDOW_TYPE__GVALUE: return getGValue(); case BuildingPhysicsPackage.WINDOW_TYPE__GLAZING_NUMBER: return getGlazingNumber(); case BuildingPhysicsPackage.WINDOW_TYPE__FRAME_RATIO: return getFrameRatio(); case BuildingPhysicsPackage.WINDOW_TYPE__EMBODIED_ENERGY: return getEmbodiedEnergy(); case BuildingPhysicsPackage.WINDOW_TYPE__EMBODIED_CARBON: return getEmbodiedCarbon(); case BuildingPhysicsPackage.WINDOW_TYPE__CONSTRUCTION_DESCRIPTION: return getConstructionDescription(); case BuildingPhysicsPackage.WINDOW_TYPE__DISPOSAL_ENERGY: return getDisposalEnergy(); case BuildingPhysicsPackage.WINDOW_TYPE__DISPOSAL_CARBON: return getDisposalCarbon(); case BuildingPhysicsPackage.WINDOW_TYPE__DISPOSAL_DESCRIPTION: return getDisposalDescription(); } return super.eGet(featureID, resolve, coreType); } /** * * * @generated */ @Override public void eSet(int featureID, Object newValue) { switch (featureID) { case BuildingPhysicsPackage.WINDOW_TYPE__WINDOW_TYPE_ID: setWindowTypeId((String) newValue); return; case BuildingPhysicsPackage.WINDOW_TYPE__NAME: setName((String) newValue); return; case BuildingPhysicsPackage.WINDOW_TYPE__UVALUE: setUValue((NullableQuantity) newValue); return; case BuildingPhysicsPackage.WINDOW_TYPE__GVALUE: setGValue((Double) newValue); return; case BuildingPhysicsPackage.WINDOW_TYPE__GLAZING_NUMBER: setGlazingNumber((Integer) newValue); return; case BuildingPhysicsPackage.WINDOW_TYPE__FRAME_RATIO: setFrameRatio((Double) newValue); return; case BuildingPhysicsPackage.WINDOW_TYPE__EMBODIED_ENERGY: setEmbodiedEnergy((NullableQuantity) newValue); return; case BuildingPhysicsPackage.WINDOW_TYPE__EMBODIED_CARBON: setEmbodiedCarbon((NullableQuantity) newValue); return; case BuildingPhysicsPackage.WINDOW_TYPE__CONSTRUCTION_DESCRIPTION: setConstructionDescription((String) newValue); return; case BuildingPhysicsPackage.WINDOW_TYPE__DISPOSAL_ENERGY: setDisposalEnergy((NullableQuantity) newValue); return; case BuildingPhysicsPackage.WINDOW_TYPE__DISPOSAL_CARBON: setDisposalCarbon((NullableQuantity) newValue); return; case BuildingPhysicsPackage.WINDOW_TYPE__DISPOSAL_DESCRIPTION: setDisposalDescription((String) newValue); return; } super.eSet(featureID, newValue); } /** * * * @generated */ @Override public void eUnset(int featureID) { switch (featureID) { case BuildingPhysicsPackage.WINDOW_TYPE__WINDOW_TYPE_ID: setWindowTypeId(WINDOW_TYPE_ID_EDEFAULT); return; case BuildingPhysicsPackage.WINDOW_TYPE__NAME: setName(NAME_EDEFAULT); return; case BuildingPhysicsPackage.WINDOW_TYPE__UVALUE: setUValue(UVALUE_EDEFAULT); return; case BuildingPhysicsPackage.WINDOW_TYPE__GVALUE: setGValue(GVALUE_EDEFAULT); return; case BuildingPhysicsPackage.WINDOW_TYPE__GLAZING_NUMBER: setGlazingNumber(GLAZING_NUMBER_EDEFAULT); return; case BuildingPhysicsPackage.WINDOW_TYPE__FRAME_RATIO: setFrameRatio(FRAME_RATIO_EDEFAULT); return; case BuildingPhysicsPackage.WINDOW_TYPE__EMBODIED_ENERGY: setEmbodiedEnergy(EMBODIED_ENERGY_EDEFAULT); return; case BuildingPhysicsPackage.WINDOW_TYPE__EMBODIED_CARBON: setEmbodiedCarbon(EMBODIED_CARBON_EDEFAULT); return; case BuildingPhysicsPackage.WINDOW_TYPE__CONSTRUCTION_DESCRIPTION: setConstructionDescription(CONSTRUCTION_DESCRIPTION_EDEFAULT); return; case BuildingPhysicsPackage.WINDOW_TYPE__DISPOSAL_ENERGY: setDisposalEnergy(DISPOSAL_ENERGY_EDEFAULT); return; case BuildingPhysicsPackage.WINDOW_TYPE__DISPOSAL_CARBON: setDisposalCarbon(DISPOSAL_CARBON_EDEFAULT); return; case BuildingPhysicsPackage.WINDOW_TYPE__DISPOSAL_DESCRIPTION: setDisposalDescription(DISPOSAL_DESCRIPTION_EDEFAULT); return; } super.eUnset(featureID); } /** * * * @generated */ @Override public boolean eIsSet(int featureID) { switch (featureID) { case BuildingPhysicsPackage.WINDOW_TYPE__WINDOW_TYPE_ID: return WINDOW_TYPE_ID_EDEFAULT == null ? windowTypeId != null : !WINDOW_TYPE_ID_EDEFAULT.equals(windowTypeId); case BuildingPhysicsPackage.WINDOW_TYPE__NAME: return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name); case BuildingPhysicsPackage.WINDOW_TYPE__UVALUE: return UVALUE_EDEFAULT == null ? uValue != null : !UVALUE_EDEFAULT.equals(uValue); case BuildingPhysicsPackage.WINDOW_TYPE__GVALUE: return gValue != GVALUE_EDEFAULT; case BuildingPhysicsPackage.WINDOW_TYPE__GLAZING_NUMBER: return glazingNumber != GLAZING_NUMBER_EDEFAULT; case BuildingPhysicsPackage.WINDOW_TYPE__FRAME_RATIO: return FRAME_RATIO_EDEFAULT == null ? frameRatio != null : !FRAME_RATIO_EDEFAULT.equals(frameRatio); case BuildingPhysicsPackage.WINDOW_TYPE__EMBODIED_ENERGY: return EMBODIED_ENERGY_EDEFAULT == null ? embodiedEnergy != null : !EMBODIED_ENERGY_EDEFAULT.equals(embodiedEnergy); case BuildingPhysicsPackage.WINDOW_TYPE__EMBODIED_CARBON: return EMBODIED_CARBON_EDEFAULT == null ? embodiedCarbon != null : !EMBODIED_CARBON_EDEFAULT.equals(embodiedCarbon); case BuildingPhysicsPackage.WINDOW_TYPE__CONSTRUCTION_DESCRIPTION: return CONSTRUCTION_DESCRIPTION_EDEFAULT == null ? constructionDescription != null : !CONSTRUCTION_DESCRIPTION_EDEFAULT.equals(constructionDescription); case BuildingPhysicsPackage.WINDOW_TYPE__DISPOSAL_ENERGY: return DISPOSAL_ENERGY_EDEFAULT == null ? disposalEnergy != null : !DISPOSAL_ENERGY_EDEFAULT.equals(disposalEnergy); case BuildingPhysicsPackage.WINDOW_TYPE__DISPOSAL_CARBON: return DISPOSAL_CARBON_EDEFAULT == null ? disposalCarbon != null : !DISPOSAL_CARBON_EDEFAULT.equals(disposalCarbon); case BuildingPhysicsPackage.WINDOW_TYPE__DISPOSAL_DESCRIPTION: return DISPOSAL_DESCRIPTION_EDEFAULT == null ? disposalDescription != null : !DISPOSAL_DESCRIPTION_EDEFAULT.equals(disposalDescription); } return super.eIsSet(featureID); } /** * * * @generated */ @Override public String toString() { if (eIsProxy()) return super.toString(); StringBuilder result = new StringBuilder(super.toString()); result.append(" (windowTypeId: "); result.append(windowTypeId); result.append(", name: "); result.append(name); result.append(", uValue: "); result.append(uValue); result.append(", gValue: "); result.append(gValue); result.append(", glazingNumber: "); result.append(glazingNumber); result.append(", frameRatio: "); result.append(frameRatio); result.append(", embodiedEnergy: "); result.append(embodiedEnergy); result.append(", embodiedCarbon: "); result.append(embodiedCarbon); result.append(", constructionDescription: "); result.append(constructionDescription); result.append(", disposalEnergy: "); result.append(disposalEnergy); result.append(", disposalCarbon: "); result.append(disposalCarbon); result.append(", disposalDescription: "); result.append(disposalDescription); result.append(')'); return result.toString(); } } //WindowTypeImpl