Commit 52890b29 authored by Johannes Eder's avatar Johannes Eder

fixed errors

Issue-Ref: 3734
Issue-Url: https://af3-developer.fortiss.org/issues/3734Signed-off-by: Johannes Eder's avatarJohannes Eder <eder@fortiss.org>
parent 771964f0
<?xml version="1.0" encoding="UTF-8"?>
<ecore:EPackage xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" name="model" nsURI="http://www.fortiss.org/af3/component" nsPrefix="org-fortiss-af3-component">
<<<<<<< HEAD
<eClassifiers xsi:type="ecore:EClass" name="ITopComponentProvider" abstract="true"
interface="true">
<eAnnotations source="http://www.eclipse.org/emf/2002/GenModel">
<details key="documentation" value="Interface to allow use other top-component providers than component architecture."/>
</eAnnotations>
<eOperations name="getTopComponent" eType="#//Component">
<eAnnotations source="http://www.eclipse.org/emf/2002/GenModel">
<details key="documentation" value="Returns the top component for elements with nested component architectures."/>
</eAnnotations>
</eOperations>
</eClassifiers>
<eClassifiers xsi:type="ecore:EClass" name="ComponentArchitecture" eSuperTypes="platform:/resource/org.fortiss.tooling.kernel/model/kernel.ecore#//IProjectRootElement platform:/resource/org.fortiss.tooling.base/model/base.ecore#//element/IHierarchicElement platform:/resource/org.fortiss.af3.project/model/project.ecore#//typesystem/IFunctionScope platform:/resource/org.fortiss.af3.project/model/project.ecore#//typesystem/ITypeScope platform:/resource/org.fortiss.tooling.kernel/model/kernel.ecore#//constraints/IConstrained #//ITopComponentProvider">
=======
<eClassifiers xsi:type="ecore:EClass" name="ComponentArchitecture" eSuperTypes="platform:/resource/org.fortiss.tooling.kernel/model/kernel.ecore#//IProjectRootElement platform:/resource/org.fortiss.tooling.base/model/base.ecore#//element/IHierarchicElement platform:/resource/org.fortiss.af3.project/model/project.ecore#//typesystem/IFunctionScope platform:/resource/org.fortiss.af3.project/model/project.ecore#//typesystem/ITypeScope">
>>>>>>> refs/heads/master
<eAnnotations source="http://www.eclipse.org/emf/2002/GenModel">
<details key="documentation" value="This is the root element of the component architecture."/>
</eAnnotations>
......
......@@ -15,9 +15,6 @@
<genEnumLiterals ecoreEnumLiteral="component.ecore#//VerificationBehaviour/useImplementation"/>
<genEnumLiterals ecoreEnumLiteral="component.ecore#//VerificationBehaviour/useContract"/>
</genEnums>
<genClasses image="false" ecoreClass="component.ecore#//ITopComponentProvider">
<genOperations ecoreOperation="component.ecore#//ITopComponentProvider/getTopComponent"/>
</genClasses>
<genClasses ecoreClass="component.ecore#//ComponentArchitecture">
<genOperations ecoreOperation="component.ecore#//ComponentArchitecture/getTopComponent"
body="return ComponentArchitectureStaticImpl.getTopComponent(this);"/>
......@@ -195,7 +192,7 @@
</genClasses>
<nestedGenPackages prefix="Behavior" basePackage="org.fortiss.af3.component.model"
disposableProviderFactory="true" ecorePackage="component.ecore#//behavior">
<genClasses ecoreClass="component.ecore#//behavior/IComponentBehaviorDefinitionSpecification"/>
<genClasses image="false" ecoreClass="component.ecore#//behavior/IComponentBehaviorDefinitionSpecification"/>
<nestedGenPackages prefix="Common" basePackage="org.fortiss.af3.component.model.behavior"
disposableProviderFactory="true" ecorePackage="component.ecore#//behavior/common">
<genClasses ecoreClass="component.ecore#//behavior/common/DataStateVariable">
......
......@@ -22,7 +22,7 @@ import java.util.function.Predicate;
import org.eclipse.emf.ecore.EObject;
import org.fortiss.af3.component.model.Channel;
import org.fortiss.af3.component.model.Component;
import org.fortiss.af3.component.model.ITopComponentProvider;
import org.fortiss.af3.component.model.ComponentArchitecture;
import org.fortiss.af3.component.model.Port;
import org.fortiss.af3.component.model.behavior.IComponentBehaviorDefinitionSpecification;
import org.fortiss.tooling.base.model.element.IHierarchicElement;
......@@ -80,8 +80,8 @@ public class ComponentUtils {
if(comp instanceof Component) {
return (Component)comp;
}
if(comp instanceof ITopComponentProvider) {
return ((ITopComponentProvider)comp).getTopComponent();
if(comp instanceof ComponentArchitecture) {
return ((ComponentArchitecture)comp).getTopComponent();
}
return null;
}
......
......@@ -116,7 +116,7 @@
containment="true"/>
</eClassifiers>
<eClassifiers xsi:type="ecore:EClass" name="ModeComponentStructureSpecification"
eSuperTypes="platform:/resource/org.fortiss.tooling.base/model/base.ecore#//element/IModelElementSpecification platform:/resource/org.fortiss.tooling.base/model/base.ecore#//element/IHierarchicElementContainer platform:/resource/org.fortiss.af3.component/model/component.ecore#//ITopComponentProvider">
eSuperTypes="platform:/resource/org.fortiss.tooling.base/model/base.ecore#//element/IModelElementSpecification platform:/resource/org.fortiss.tooling.base/model/base.ecore#//element/IHierarchicElementContainer">
<eOperations name="getTopComponent" eType="ecore:EClass platform:/resource/org.fortiss.af3.component/model/component.ecore#//Component">
<eAnnotations source="http://www.eclipse.org/emf/2002/GenModel">
<details key="body" value="if(getContainedElements().size()==0){&#xA;return null;&#xA;}&#xA;return (Component) getContainedElements().get(0);"/>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment