org.nasdanika.html.model.bootstrap.impl.ItemImpl Maven / Gradle / Ivy
/**
*/
package org.nasdanika.html.model.bootstrap.impl;
import org.eclipse.emf.ecore.EClass;
import org.nasdanika.html.bootstrap.Color;
import org.nasdanika.html.model.bootstrap.BootstrapPackage;
import org.nasdanika.html.model.bootstrap.Item;
import org.nasdanika.ncore.impl.ModelElementImpl;
/**
*
* An implementation of the model object 'Item'.
*
*
* The following features are implemented:
*
*
* - {@link org.nasdanika.html.model.bootstrap.impl.ItemImpl#isActive Active}
* - {@link org.nasdanika.html.model.bootstrap.impl.ItemImpl#isDisabled Disabled}
* - {@link org.nasdanika.html.model.bootstrap.impl.ItemImpl#getColor Color}
*
*
* @generated
*/
public abstract class ItemImpl extends ModelElementImpl implements Item {
/**
* The default value of the '{@link #isActive() Active}' attribute.
*
*
* @see #isActive()
* @generated
* @ordered
*/
protected static final boolean ACTIVE_EDEFAULT = false;
/**
* The default value of the '{@link #isDisabled() Disabled}' attribute.
*
*
* @see #isDisabled()
* @generated
* @ordered
*/
protected static final boolean DISABLED_EDEFAULT = false;
/**
* The default value of the '{@link #getColor() Color}' attribute.
*
*
* @see #getColor()
* @generated
* @ordered
*/
protected static final Color COLOR_EDEFAULT = null;
/**
*
*
* @generated
*/
protected ItemImpl() {
super();
}
/**
*
*
* @generated
*/
@Override
protected EClass eStaticClass() {
return BootstrapPackage.Literals.ITEM;
}
/**
*
*
* @generated
*/
@Override
public boolean isActive() {
return (Boolean)eDynamicGet(BootstrapPackage.ITEM__ACTIVE, BootstrapPackage.Literals.ITEM__ACTIVE, true, true);
}
/**
*
*
* @generated
*/
@Override
public void setActive(boolean newActive) {
eDynamicSet(BootstrapPackage.ITEM__ACTIVE, BootstrapPackage.Literals.ITEM__ACTIVE, newActive);
}
/**
*
*
* @generated
*/
@Override
public boolean isDisabled() {
return (Boolean)eDynamicGet(BootstrapPackage.ITEM__DISABLED, BootstrapPackage.Literals.ITEM__DISABLED, true, true);
}
/**
*
*
* @generated
*/
@Override
public void setDisabled(boolean newDisabled) {
eDynamicSet(BootstrapPackage.ITEM__DISABLED, BootstrapPackage.Literals.ITEM__DISABLED, newDisabled);
}
/**
*
*
* @generated
*/
@Override
public Color getColor() {
return (Color)eDynamicGet(BootstrapPackage.ITEM__COLOR, BootstrapPackage.Literals.ITEM__COLOR, true, true);
}
/**
*
*
* @generated
*/
@Override
public void setColor(Color newColor) {
eDynamicSet(BootstrapPackage.ITEM__COLOR, BootstrapPackage.Literals.ITEM__COLOR, newColor);
}
/**
*
*
* @generated
*/
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
case BootstrapPackage.ITEM__ACTIVE:
return isActive();
case BootstrapPackage.ITEM__DISABLED:
return isDisabled();
case BootstrapPackage.ITEM__COLOR:
return getColor();
}
return super.eGet(featureID, resolve, coreType);
}
/**
*
*
* @generated
*/
@Override
public void eSet(int featureID, Object newValue) {
switch (featureID) {
case BootstrapPackage.ITEM__ACTIVE:
setActive((Boolean)newValue);
return;
case BootstrapPackage.ITEM__DISABLED:
setDisabled((Boolean)newValue);
return;
case BootstrapPackage.ITEM__COLOR:
setColor((Color)newValue);
return;
}
super.eSet(featureID, newValue);
}
/**
*
*
* @generated
*/
@Override
public void eUnset(int featureID) {
switch (featureID) {
case BootstrapPackage.ITEM__ACTIVE:
setActive(ACTIVE_EDEFAULT);
return;
case BootstrapPackage.ITEM__DISABLED:
setDisabled(DISABLED_EDEFAULT);
return;
case BootstrapPackage.ITEM__COLOR:
setColor(COLOR_EDEFAULT);
return;
}
super.eUnset(featureID);
}
/**
*
*
* @generated
*/
@Override
public boolean eIsSet(int featureID) {
switch (featureID) {
case BootstrapPackage.ITEM__ACTIVE:
return isActive() != ACTIVE_EDEFAULT;
case BootstrapPackage.ITEM__DISABLED:
return isDisabled() != DISABLED_EDEFAULT;
case BootstrapPackage.ITEM__COLOR:
return COLOR_EDEFAULT == null ? getColor() != null : !COLOR_EDEFAULT.equals(getColor());
}
return super.eIsSet(featureID);
}
} //ItemImpl
© 2015 - 2024 Weber Informatics LLC | Privacy Policy