org.nasdanika.models.rules.impl.FailureImpl Maven / Gradle / Ivy
The newest version!
/**
*/
package org.nasdanika.models.rules.impl;
import org.eclipse.emf.common.notify.NotificationChain;
import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.ecore.InternalEObject;
import org.nasdanika.models.rules.Failure;
import org.nasdanika.models.rules.RulesPackage;
/**
*
* An implementation of the model object 'Failure'.
*
*
* The following features are implemented:
*
*
* - {@link org.nasdanika.models.rules.impl.FailureImpl#getCause Cause}
*
*
* @generated
*/
public class FailureImpl extends InspectionResultImpl implements Failure {
/**
*
*
* @generated
*/
protected FailureImpl() {
super();
}
/**
*
*
* @generated
*/
@Override
protected EClass eStaticClass() {
return RulesPackage.Literals.FAILURE;
}
/**
*
*
* @generated
*/
@Override
public org.nasdanika.ncore.Throwable getCause() {
return (org.nasdanika.ncore.Throwable)eDynamicGet(RulesPackage.FAILURE__CAUSE, RulesPackage.Literals.FAILURE__CAUSE, true, true);
}
/**
*
*
* @generated
*/
public NotificationChain basicSetCause(org.nasdanika.ncore.Throwable newCause, NotificationChain msgs) {
msgs = eDynamicInverseAdd((InternalEObject)newCause, RulesPackage.FAILURE__CAUSE, msgs);
return msgs;
}
/**
*
*
* @generated
*/
@Override
public void setCause(org.nasdanika.ncore.Throwable newCause) {
eDynamicSet(RulesPackage.FAILURE__CAUSE, RulesPackage.Literals.FAILURE__CAUSE, newCause);
}
/**
*
*
* @generated
*/
@Override
public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
switch (featureID) {
case RulesPackage.FAILURE__CAUSE:
return basicSetCause(null, msgs);
}
return super.eInverseRemove(otherEnd, featureID, msgs);
}
/**
*
*
* @generated
*/
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
case RulesPackage.FAILURE__CAUSE:
return getCause();
}
return super.eGet(featureID, resolve, coreType);
}
/**
*
*
* @generated
*/
@Override
public void eSet(int featureID, Object newValue) {
switch (featureID) {
case RulesPackage.FAILURE__CAUSE:
setCause((org.nasdanika.ncore.Throwable)newValue);
return;
}
super.eSet(featureID, newValue);
}
/**
*
*
* @generated
*/
@Override
public void eUnset(int featureID) {
switch (featureID) {
case RulesPackage.FAILURE__CAUSE:
setCause((org.nasdanika.ncore.Throwable)null);
return;
}
super.eUnset(featureID);
}
/**
*
*
* @generated
*/
@Override
public boolean eIsSet(int featureID) {
switch (featureID) {
case RulesPackage.FAILURE__CAUSE:
return getCause() != null;
}
return super.eIsSet(featureID);
}
} //FailureImpl