From 6f88c4bd4e91728cea62505e893b0ce300baf7fc Mon Sep 17 00:00:00 2001 From: Kristóf Marussy Date: Thu, 7 Feb 2019 18:24:45 +0100 Subject: Ecore2Cft transformation --- .../faulttree/model/cft/impl/CftFactoryImpl.java | 8 +- .../faulttree/model/cft/impl/CftPackageImpl.java | 42 ++++-- .../model/cft/impl/ComponentDefinitionImpl.java | 11 +- .../faulttree/model/cft/impl/ComponentImpl.java | 70 +++++++++ .../faulttree/model/cft/impl/InputEventImpl.java | 164 +++++++++++++++++++++ .../faulttree/model/cft/impl/InputImpl.java | 55 ++++--- .../faulttree/model/cft/impl/IntputEventImpl.java | 164 --------------------- 7 files changed, 297 insertions(+), 217 deletions(-) create mode 100644 Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/InputEventImpl.java delete mode 100644 Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/IntputEventImpl.java (limited to 'Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl') diff --git a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/CftFactoryImpl.java b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/CftFactoryImpl.java index 33778461..6eac2861 100644 --- a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/CftFactoryImpl.java +++ b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/CftFactoryImpl.java @@ -58,7 +58,7 @@ public class CftFactoryImpl extends EFactoryImpl implements CftFactory { switch (eClass.getClassifierID()) { case CftPackage.COMPONENT_DEFINITION: return createComponentDefinition(); case CftPackage.BASIC_EVENT_DEFINITION: return createBasicEventDefinition(); - case CftPackage.INTPUT_EVENT: return createIntputEvent(); + case CftPackage.INPUT_EVENT: return createInputEvent(); case CftPackage.AND_GATE_DEFINITION: return createAndGateDefinition(); case CftPackage.OR_GATE_DEFINITION: return createOrGateDefinition(); case CftPackage.KOF_MGATE_DEFINITION: return createKOfMGateDefinition(); @@ -100,9 +100,9 @@ public class CftFactoryImpl extends EFactoryImpl implements CftFactory { * @generated */ @Override - public IntputEvent createIntputEvent() { - IntputEventImpl intputEvent = new IntputEventImpl(); - return intputEvent; + public InputEvent createInputEvent() { + InputEventImpl inputEvent = new InputEventImpl(); + return inputEvent; } /** diff --git a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/CftPackageImpl.java b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/CftPackageImpl.java index f03fa0ba..1d6b6a23 100644 --- a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/CftPackageImpl.java +++ b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/CftPackageImpl.java @@ -14,7 +14,7 @@ import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.EventDeclaration; import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.EventDefinition; import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.GateDefinition; import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.Input; -import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.IntputEvent; +import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.InputEvent; import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.KOfMGateDefinition; import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.OrGateDefinition; import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.Output; @@ -68,7 +68,7 @@ public class CftPackageImpl extends EPackageImpl implements CftPackage { * * @generated */ - private EClass intputEventEClass = null; + private EClass inputEventEClass = null; /** * @@ -303,8 +303,8 @@ public class CftPackageImpl extends EPackageImpl implements CftPackage { * @generated */ @Override - public EClass getIntputEvent() { - return intputEventEClass; + public EClass getInputEvent() { + return inputEventEClass; } /** @@ -313,8 +313,8 @@ public class CftPackageImpl extends EPackageImpl implements CftPackage { * @generated */ @Override - public EAttribute getIntputEvent_Multiple() { - return (EAttribute)intputEventEClass.getEStructuralFeatures().get(0); + public EAttribute getInputEvent_Multiple() { + return (EAttribute)inputEventEClass.getEStructuralFeatures().get(0); } /** @@ -457,6 +457,16 @@ public class CftPackageImpl extends EPackageImpl implements CftPackage { return (EReference)componentEClass.getEStructuralFeatures().get(2); } + /** + * + * + * @generated + */ + @Override + public EAttribute getComponent_Name() { + return (EAttribute)componentEClass.getEStructuralFeatures().get(3); + } + /** * * @@ -473,7 +483,7 @@ public class CftPackageImpl extends EPackageImpl implements CftPackage { * @generated */ @Override - public EReference getInput_IntputEvent() { + public EReference getInput_InputEvent() { return (EReference)inputEClass.getEStructuralFeatures().get(0); } @@ -610,8 +620,8 @@ public class CftPackageImpl extends EPackageImpl implements CftPackage { basicEventDefinitionEClass = createEClass(BASIC_EVENT_DEFINITION); createEReference(basicEventDefinitionEClass, BASIC_EVENT_DEFINITION__DISTRIBUTION); - intputEventEClass = createEClass(INTPUT_EVENT); - createEAttribute(intputEventEClass, INTPUT_EVENT__MULTIPLE); + inputEventEClass = createEClass(INPUT_EVENT); + createEAttribute(inputEventEClass, INPUT_EVENT__MULTIPLE); eventDeclarationEClass = createEClass(EVENT_DECLARATION); createEAttribute(eventDeclarationEClass, EVENT_DECLARATION__NAME); @@ -632,9 +642,10 @@ public class CftPackageImpl extends EPackageImpl implements CftPackage { createEReference(componentEClass, COMPONENT__INPUTS); createEReference(componentEClass, COMPONENT__OUTPUTS); createEReference(componentEClass, COMPONENT__COMPONENT_DEFINITION); + createEAttribute(componentEClass, COMPONENT__NAME); inputEClass = createEClass(INPUT); - createEReference(inputEClass, INPUT__INTPUT_EVENT); + createEReference(inputEClass, INPUT__INPUT_EVENT); createEReference(inputEClass, INPUT__COMPONENT); createEReference(inputEClass, INPUT__INCOMING_CONNECTIONS); @@ -682,14 +693,14 @@ public class CftPackageImpl extends EPackageImpl implements CftPackage { eventDefinitionEClass.getESuperTypes().add(this.getEventDeclaration()); gateDefinitionEClass.getESuperTypes().add(this.getEventDefinition()); basicEventDefinitionEClass.getESuperTypes().add(this.getEventDefinition()); - intputEventEClass.getESuperTypes().add(this.getEventDeclaration()); + inputEventEClass.getESuperTypes().add(this.getEventDeclaration()); andGateDefinitionEClass.getESuperTypes().add(this.getGateDefinition()); orGateDefinitionEClass.getESuperTypes().add(this.getGateDefinition()); kOfMGateDefinitionEClass.getESuperTypes().add(this.getGateDefinition()); // Initialize classes, features, and operations; add parameters initEClass(componentDefinitionEClass, ComponentDefinition.class, "ComponentDefinition", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getComponentDefinition_InputEvents(), this.getIntputEvent(), null, "inputEvents", null, 0, -1, ComponentDefinition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getComponentDefinition_InputEvents(), this.getInputEvent(), null, "inputEvents", null, 0, -1, ComponentDefinition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getComponentDefinition_EventDefinitions(), this.getEventDefinition(), null, "eventDefinitions", null, 0, -1, ComponentDefinition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getComponentDefinition_OutputEvents(), this.getEventDeclaration(), null, "outputEvents", null, 0, -1, ComponentDefinition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getComponentDefinition_Name(), ecorePackage.getEString(), "name", null, 0, 1, ComponentDefinition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); @@ -702,8 +713,8 @@ public class CftPackageImpl extends EPackageImpl implements CftPackage { initEClass(basicEventDefinitionEClass, BasicEventDefinition.class, "BasicEventDefinition", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEReference(getBasicEventDefinition_Distribution(), theFtPackage.getDistribution(), null, "distribution", null, 1, 1, BasicEventDefinition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEClass(intputEventEClass, IntputEvent.class, "IntputEvent", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getIntputEvent_Multiple(), ecorePackage.getEBoolean(), "multiple", null, 0, 1, IntputEvent.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEClass(inputEventEClass, InputEvent.class, "InputEvent", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEAttribute(getInputEvent_Multiple(), ecorePackage.getEBoolean(), "multiple", null, 0, 1, InputEvent.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(eventDeclarationEClass, EventDeclaration.class, "EventDeclaration", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getEventDeclaration_Name(), ecorePackage.getEString(), "name", null, 0, 1, EventDeclaration.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); @@ -724,9 +735,10 @@ public class CftPackageImpl extends EPackageImpl implements CftPackage { initEReference(getComponent_Inputs(), this.getInput(), this.getInput_Component(), "inputs", null, 0, -1, Component.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getComponent_Outputs(), this.getOutput(), this.getOutput_Component(), "outputs", null, 0, -1, Component.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getComponent_ComponentDefinition(), this.getComponentDefinition(), null, "componentDefinition", null, 1, 1, Component.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEAttribute(getComponent_Name(), ecorePackage.getEString(), "name", null, 0, 1, Component.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(inputEClass, Input.class, "Input", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getInput_IntputEvent(), this.getIntputEvent(), null, "intputEvent", null, 1, 1, Input.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getInput_InputEvent(), this.getInputEvent(), null, "inputEvent", null, 1, 1, Input.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getInput_Component(), this.getComponent(), this.getComponent_Inputs(), "component", null, 1, 1, Input.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getInput_IncomingConnections(), this.getConnection(), this.getConnection_Input(), "incomingConnections", null, 0, -1, Input.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); diff --git a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/ComponentDefinitionImpl.java b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/ComponentDefinitionImpl.java index 58a476f3..3b79fb0c 100644 --- a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/ComponentDefinitionImpl.java +++ b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/ComponentDefinitionImpl.java @@ -6,8 +6,7 @@ import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.CftPackage; import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.ComponentDefinition; import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.EventDeclaration; import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.EventDefinition; -import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.IntputEvent; - +import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.InputEvent; import java.util.Collection; import org.eclipse.emf.common.notify.Notification; @@ -50,7 +49,7 @@ public class ComponentDefinitionImpl extends MinimalEObjectImpl.Container implem * @generated * @ordered */ - protected EList inputEvents; + protected EList inputEvents; /** * The cached value of the '{@link #getEventDefinitions() Event Definitions}' containment reference list. @@ -117,9 +116,9 @@ public class ComponentDefinitionImpl extends MinimalEObjectImpl.Container implem * @generated */ @Override - public EList getInputEvents() { + public EList getInputEvents() { if (inputEvents == null) { - inputEvents = new EObjectContainmentEList(IntputEvent.class, this, CftPackage.COMPONENT_DEFINITION__INPUT_EVENTS); + inputEvents = new EObjectContainmentEList(InputEvent.class, this, CftPackage.COMPONENT_DEFINITION__INPUT_EVENTS); } return inputEvents; } @@ -220,7 +219,7 @@ public class ComponentDefinitionImpl extends MinimalEObjectImpl.Container implem switch (featureID) { case CftPackage.COMPONENT_DEFINITION__INPUT_EVENTS: getInputEvents().clear(); - getInputEvents().addAll((Collection)newValue); + getInputEvents().addAll((Collection)newValue); return; case CftPackage.COMPONENT_DEFINITION__EVENT_DEFINITIONS: getEventDefinitions().clear(); diff --git a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/ComponentImpl.java b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/ComponentImpl.java index 6d23dc78..847b6ee1 100644 --- a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/ComponentImpl.java +++ b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/ComponentImpl.java @@ -35,6 +35,7 @@ import org.eclipse.emf.ecore.util.InternalEList; *
  • {@link hu.bme.mit.inf.dslreasoner.faulttree.model.cft.impl.ComponentImpl#getInputs Inputs}
  • *
  • {@link hu.bme.mit.inf.dslreasoner.faulttree.model.cft.impl.ComponentImpl#getOutputs Outputs}
  • *
  • {@link hu.bme.mit.inf.dslreasoner.faulttree.model.cft.impl.ComponentImpl#getComponentDefinition Component Definition}
  • + *
  • {@link hu.bme.mit.inf.dslreasoner.faulttree.model.cft.impl.ComponentImpl#getName Name}
  • * * * @generated @@ -70,6 +71,26 @@ public class ComponentImpl extends MinimalEObjectImpl.Container implements Compo */ protected ComponentDefinition componentDefinition; + /** + * 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; + /** * * @@ -155,6 +176,29 @@ public class ComponentImpl extends MinimalEObjectImpl.Container implements Compo eNotify(new ENotificationImpl(this, Notification.SET, CftPackage.COMPONENT__COMPONENT_DEFINITION, oldComponentDefinition, componentDefinition)); } + /** + * + * + * @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, CftPackage.COMPONENT__NAME, oldName, name)); + } + /** * * @@ -203,6 +247,8 @@ public class ComponentImpl extends MinimalEObjectImpl.Container implements Compo case CftPackage.COMPONENT__COMPONENT_DEFINITION: if (resolve) return getComponentDefinition(); return basicGetComponentDefinition(); + case CftPackage.COMPONENT__NAME: + return getName(); } return super.eGet(featureID, resolve, coreType); } @@ -227,6 +273,9 @@ public class ComponentImpl extends MinimalEObjectImpl.Container implements Compo case CftPackage.COMPONENT__COMPONENT_DEFINITION: setComponentDefinition((ComponentDefinition)newValue); return; + case CftPackage.COMPONENT__NAME: + setName((String)newValue); + return; } super.eSet(featureID, newValue); } @@ -248,6 +297,9 @@ public class ComponentImpl extends MinimalEObjectImpl.Container implements Compo case CftPackage.COMPONENT__COMPONENT_DEFINITION: setComponentDefinition((ComponentDefinition)null); return; + case CftPackage.COMPONENT__NAME: + setName(NAME_EDEFAULT); + return; } super.eUnset(featureID); } @@ -266,8 +318,26 @@ public class ComponentImpl extends MinimalEObjectImpl.Container implements Compo return outputs != null && !outputs.isEmpty(); case CftPackage.COMPONENT__COMPONENT_DEFINITION: return componentDefinition != null; + case CftPackage.COMPONENT__NAME: + return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name); } return super.eIsSet(featureID); } + /** + * + * + * @generated + */ + @Override + public String toString() { + if (eIsProxy()) return super.toString(); + + StringBuilder result = new StringBuilder(super.toString()); + result.append(" (name: "); + result.append(name); + result.append(')'); + return result.toString(); + } + } //ComponentImpl diff --git a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/InputEventImpl.java b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/InputEventImpl.java new file mode 100644 index 00000000..8432e29b --- /dev/null +++ b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/InputEventImpl.java @@ -0,0 +1,164 @@ +/** + */ +package hu.bme.mit.inf.dslreasoner.faulttree.model.cft.impl; + +import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.CftPackage; +import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.InputEvent; + +import org.eclipse.emf.common.notify.Notification; + +import org.eclipse.emf.ecore.EClass; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; + +/** + * + * An implementation of the model object 'Input Event'. + * + *

    + * The following features are implemented: + *

    + *
      + *
    • {@link hu.bme.mit.inf.dslreasoner.faulttree.model.cft.impl.InputEventImpl#isMultiple Multiple}
    • + *
    + * + * @generated + */ +public class InputEventImpl extends EventDeclarationImpl implements InputEvent { + /** + * The default value of the '{@link #isMultiple() Multiple}' attribute. + * + * + * @see #isMultiple() + * @generated + * @ordered + */ + protected static final boolean MULTIPLE_EDEFAULT = false; + + /** + * The cached value of the '{@link #isMultiple() Multiple}' attribute. + * + * + * @see #isMultiple() + * @generated + * @ordered + */ + protected boolean multiple = MULTIPLE_EDEFAULT; + + /** + * + * + * @generated + */ + protected InputEventImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return CftPackage.Literals.INPUT_EVENT; + } + + /** + * + * + * @generated + */ + @Override + public boolean isMultiple() { + return multiple; + } + + /** + * + * + * @generated + */ + @Override + public void setMultiple(boolean newMultiple) { + boolean oldMultiple = multiple; + multiple = newMultiple; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, CftPackage.INPUT_EVENT__MULTIPLE, oldMultiple, multiple)); + } + + /** + * + * + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case CftPackage.INPUT_EVENT__MULTIPLE: + return isMultiple(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * + * + * @generated + */ + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case CftPackage.INPUT_EVENT__MULTIPLE: + setMultiple((Boolean)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * + * + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case CftPackage.INPUT_EVENT__MULTIPLE: + setMultiple(MULTIPLE_EDEFAULT); + return; + } + super.eUnset(featureID); + } + + /** + * + * + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case CftPackage.INPUT_EVENT__MULTIPLE: + return multiple != MULTIPLE_EDEFAULT; + } + return super.eIsSet(featureID); + } + + /** + * + * + * @generated + */ + @Override + public String toString() { + if (eIsProxy()) return super.toString(); + + StringBuilder result = new StringBuilder(super.toString()); + result.append(" (multiple: "); + result.append(multiple); + result.append(')'); + return result.toString(); + } + +} //InputEventImpl diff --git a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/InputImpl.java b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/InputImpl.java index eda5fea0..aa560064 100644 --- a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/InputImpl.java +++ b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/InputImpl.java @@ -6,8 +6,7 @@ import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.CftPackage; import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.Component; import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.Connection; import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.Input; -import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.IntputEvent; - +import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.InputEvent; import java.util.Collection; import org.eclipse.emf.common.notify.Notification; @@ -33,7 +32,7 @@ import org.eclipse.emf.ecore.util.InternalEList; * The following features are implemented: *

    *
      - *
    • {@link hu.bme.mit.inf.dslreasoner.faulttree.model.cft.impl.InputImpl#getIntputEvent Intput Event}
    • + *
    • {@link hu.bme.mit.inf.dslreasoner.faulttree.model.cft.impl.InputImpl#getInputEvent Input Event}
    • *
    • {@link hu.bme.mit.inf.dslreasoner.faulttree.model.cft.impl.InputImpl#getComponent Component}
    • *
    • {@link hu.bme.mit.inf.dslreasoner.faulttree.model.cft.impl.InputImpl#getIncomingConnections Incoming Connections}
    • *
    @@ -42,14 +41,14 @@ import org.eclipse.emf.ecore.util.InternalEList; */ public class InputImpl extends MinimalEObjectImpl.Container implements Input { /** - * The cached value of the '{@link #getIntputEvent() Intput Event}' reference. + * The cached value of the '{@link #getInputEvent() Input Event}' reference. * * - * @see #getIntputEvent() + * @see #getInputEvent() * @generated * @ordered */ - protected IntputEvent intputEvent; + protected InputEvent inputEvent; /** * The cached value of the '{@link #getIncomingConnections() Incoming Connections}' containment reference list. @@ -86,16 +85,16 @@ public class InputImpl extends MinimalEObjectImpl.Container implements Input { * @generated */ @Override - public IntputEvent getIntputEvent() { - if (intputEvent != null && intputEvent.eIsProxy()) { - InternalEObject oldIntputEvent = (InternalEObject)intputEvent; - intputEvent = (IntputEvent)eResolveProxy(oldIntputEvent); - if (intputEvent != oldIntputEvent) { + public InputEvent getInputEvent() { + if (inputEvent != null && inputEvent.eIsProxy()) { + InternalEObject oldInputEvent = (InternalEObject)inputEvent; + inputEvent = (InputEvent)eResolveProxy(oldInputEvent); + if (inputEvent != oldInputEvent) { if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, CftPackage.INPUT__INTPUT_EVENT, oldIntputEvent, intputEvent)); + eNotify(new ENotificationImpl(this, Notification.RESOLVE, CftPackage.INPUT__INPUT_EVENT, oldInputEvent, inputEvent)); } } - return intputEvent; + return inputEvent; } /** @@ -103,8 +102,8 @@ public class InputImpl extends MinimalEObjectImpl.Container implements Input { * * @generated */ - public IntputEvent basicGetIntputEvent() { - return intputEvent; + public InputEvent basicGetInputEvent() { + return inputEvent; } /** @@ -113,11 +112,11 @@ public class InputImpl extends MinimalEObjectImpl.Container implements Input { * @generated */ @Override - public void setIntputEvent(IntputEvent newIntputEvent) { - IntputEvent oldIntputEvent = intputEvent; - intputEvent = newIntputEvent; + public void setInputEvent(InputEvent newInputEvent) { + InputEvent oldInputEvent = inputEvent; + inputEvent = newInputEvent; if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, CftPackage.INPUT__INTPUT_EVENT, oldIntputEvent, intputEvent)); + eNotify(new ENotificationImpl(this, Notification.SET, CftPackage.INPUT__INPUT_EVENT, oldInputEvent, inputEvent)); } /** @@ -233,9 +232,9 @@ public class InputImpl extends MinimalEObjectImpl.Container implements Input { @Override public Object eGet(int featureID, boolean resolve, boolean coreType) { switch (featureID) { - case CftPackage.INPUT__INTPUT_EVENT: - if (resolve) return getIntputEvent(); - return basicGetIntputEvent(); + case CftPackage.INPUT__INPUT_EVENT: + if (resolve) return getInputEvent(); + return basicGetInputEvent(); case CftPackage.INPUT__COMPONENT: return getComponent(); case CftPackage.INPUT__INCOMING_CONNECTIONS: @@ -253,8 +252,8 @@ public class InputImpl extends MinimalEObjectImpl.Container implements Input { @Override public void eSet(int featureID, Object newValue) { switch (featureID) { - case CftPackage.INPUT__INTPUT_EVENT: - setIntputEvent((IntputEvent)newValue); + case CftPackage.INPUT__INPUT_EVENT: + setInputEvent((InputEvent)newValue); return; case CftPackage.INPUT__COMPONENT: setComponent((Component)newValue); @@ -275,8 +274,8 @@ public class InputImpl extends MinimalEObjectImpl.Container implements Input { @Override public void eUnset(int featureID) { switch (featureID) { - case CftPackage.INPUT__INTPUT_EVENT: - setIntputEvent((IntputEvent)null); + case CftPackage.INPUT__INPUT_EVENT: + setInputEvent((InputEvent)null); return; case CftPackage.INPUT__COMPONENT: setComponent((Component)null); @@ -296,8 +295,8 @@ public class InputImpl extends MinimalEObjectImpl.Container implements Input { @Override public boolean eIsSet(int featureID) { switch (featureID) { - case CftPackage.INPUT__INTPUT_EVENT: - return intputEvent != null; + case CftPackage.INPUT__INPUT_EVENT: + return inputEvent != null; case CftPackage.INPUT__COMPONENT: return getComponent() != null; case CftPackage.INPUT__INCOMING_CONNECTIONS: diff --git a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/IntputEventImpl.java b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/IntputEventImpl.java deleted file mode 100644 index ea22452f..00000000 --- a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/cft/impl/IntputEventImpl.java +++ /dev/null @@ -1,164 +0,0 @@ -/** - */ -package hu.bme.mit.inf.dslreasoner.faulttree.model.cft.impl; - -import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.CftPackage; -import hu.bme.mit.inf.dslreasoner.faulttree.model.cft.IntputEvent; - -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -/** - * - * An implementation of the model object 'Intput Event'. - * - *

    - * The following features are implemented: - *

    - *
      - *
    • {@link hu.bme.mit.inf.dslreasoner.faulttree.model.cft.impl.IntputEventImpl#isMultiple Multiple}
    • - *
    - * - * @generated - */ -public class IntputEventImpl extends EventDeclarationImpl implements IntputEvent { - /** - * The default value of the '{@link #isMultiple() Multiple}' attribute. - * - * - * @see #isMultiple() - * @generated - * @ordered - */ - protected static final boolean MULTIPLE_EDEFAULT = false; - - /** - * The cached value of the '{@link #isMultiple() Multiple}' attribute. - * - * - * @see #isMultiple() - * @generated - * @ordered - */ - protected boolean multiple = MULTIPLE_EDEFAULT; - - /** - * - * - * @generated - */ - protected IntputEventImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return CftPackage.Literals.INTPUT_EVENT; - } - - /** - * - * - * @generated - */ - @Override - public boolean isMultiple() { - return multiple; - } - - /** - * - * - * @generated - */ - @Override - public void setMultiple(boolean newMultiple) { - boolean oldMultiple = multiple; - multiple = newMultiple; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, CftPackage.INTPUT_EVENT__MULTIPLE, oldMultiple, multiple)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case CftPackage.INTPUT_EVENT__MULTIPLE: - return isMultiple(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case CftPackage.INTPUT_EVENT__MULTIPLE: - setMultiple((Boolean)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case CftPackage.INTPUT_EVENT__MULTIPLE: - setMultiple(MULTIPLE_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case CftPackage.INTPUT_EVENT__MULTIPLE: - return multiple != MULTIPLE_EDEFAULT; - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() { - if (eIsProxy()) return super.toString(); - - StringBuilder result = new StringBuilder(super.toString()); - result.append(" (multiple: "); - result.append(multiple); - result.append(')'); - return result.toString(); - } - -} //IntputEventImpl -- cgit v1.2.3-70-g09d2