Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCéline Janssens2015-07-27 07:58:43 +0000
committerGerrit Code Review @ Eclipse.org2015-07-30 09:19:09 +0000
commitf45cc3605cbec5d36874de77a47a6bcf5934ad73 (patch)
tree34e7d6d5cbeefb501df70d035023bbab764072fb
parent1cc8b194562840d9dcbdab849b3e0f4db95c11d9 (diff)
downloadorg.eclipse.papyrus-rt-f45cc3605cbec5d36874de77a47a6bcf5934ad73.tar.gz
org.eclipse.papyrus-rt-f45cc3605cbec5d36874de77a47a6bcf5934ad73.tar.xz
org.eclipse.papyrus-rt-f45cc3605cbec5d36874de77a47a6bcf5934ad73.zip
Bug 473064 - [tooling] A port RT is automaticaly created when DnD on a
Capsule Change-Id: If6a80e76af2454199242c684cebd85a6ad48bb59 Signed-off-by: Céline Janssens <Celine.Janssens@all4tec.net>
-rw-r--r--plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/META-INF/MANIFEST.MF9
-rw-r--r--plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/propertyView/UML-RT/Environment.xmi10
-rw-r--r--plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/propertyView/UML-RT/ui/SingleRTPort.xwt91
-rw-r--r--plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/propertyView/UML-RT/uml-rt.ctx385
-rw-r--r--plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/modelelement/RTStereotypeModelElement.java116
-rw-r--r--plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/modelelement/RTStereotypeModelElementFactory.java61
-rw-r--r--plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/modelelement/UMLRTExtModelElement.java94
-rw-r--r--plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/modelelement/UMLRTExtModelElementFactory.java22
-rw-r--r--plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/modelelement/UMLRTModelElementFactory.java13
-rw-r--r--plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/util/Constants.java22
-rw-r--r--plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/util/RTPortHelper.java63
-rw-r--r--plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/widgets/PortRTKindEnum.java57
-rw-r--r--plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/widgets/PortRTKindObservableValue.java284
13 files changed, 974 insertions, 253 deletions
diff --git a/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/META-INF/MANIFEST.MF b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/META-INF/MANIFEST.MF
index 26e47f506..87b5d215c 100644
--- a/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/META-INF/MANIFEST.MF
+++ b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/META-INF/MANIFEST.MF
@@ -18,6 +18,13 @@ Require-Bundle: org.eclipse.ui,
org.eclipse.papyrus.infra.core.log;bundle-version="1.1.0",
org.eclipse.emf.transaction;bundle-version="1.9.0",
org.eclipse.papyrusrt.umlrt.profile;bundle-version="0.7.0",
- org.eclipse.papyrusrt.umlrt.core;bundle-version="0.7.0"
+ org.eclipse.papyrusrt.umlrt.core;bundle-version="0.7.0",
+ org.eclipse.papyrus.infra.tools,
+ org.eclipse.ui.views.properties.tabbed,
+ org.eclipse.jface.databinding,
+ org.eclipse.core.databinding.property;bundle-version="1.5.0",
+ org.eclipse.papyrus.uml.diagram.common;bundle-version="1.1.0",
+ org.eclipse.papyrus.infra.gmfdiag.common
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
Bundle-ActivationPolicy: lazy
+Import-Package: org.eclipse.papyrus.uml.tools.utils
diff --git a/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/propertyView/UML-RT/Environment.xmi b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/propertyView/UML-RT/Environment.xmi
index 0bcd7f7e3..aa5b5f1e4 100644
--- a/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/propertyView/UML-RT/Environment.xmi
+++ b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/propertyView/UML-RT/Environment.xmi
@@ -1,4 +1,6 @@
-<?xml version="1.0" encoding="ASCII"?>
-<environment:Environment xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:environment="http://www.eclipse.org/papyrus/properties/environment/0.9">
- <modelElementFactories name="UMLRTExtModelElementFactory" factoryClass="org.eclipse.papyrusrt.umlrt.tooling.properties.modelelement.UMLRTExtModelElementFactory"/>
- </environment:Environment>
+<?xml version="1.0" encoding="ASCII"?>
+<environment:Environment xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:environment="http://www.eclipse.org/papyrus/properties/environment/0.9">
+ <modelElementFactories name="UMLRTExtModelElementFactory" factoryClass="org.eclipse.papyrusrt.umlrt.tooling.properties.modelelement.UMLRTExtModelElementFactory"/>
+ <modelElementFactories name="RT Stereotype Model Element Factory" factoryClass="org.eclipse.papyrusrt.umlrt.tooling.properties.modelelement.RTStereotypeModelElementFactory"/>
+ <modelElementFactories name="UML RT Model Element Factory" factoryClass="org.eclipse.papyrusrt.umlrt.tooling.properties.modelelement.UMLRTModelElementFactory"/>
+</environment:Environment>
diff --git a/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/propertyView/UML-RT/ui/SingleRTPort.xwt b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/propertyView/UML-RT/ui/SingleRTPort.xwt
index da5ad7b59..2936ac9b2 100644
--- a/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/propertyView/UML-RT/ui/SingleRTPort.xwt
+++ b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/propertyView/UML-RT/ui/SingleRTPort.xwt
@@ -1,32 +1,61 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<Composite xmlns:x="http://www.eclipse.org/xwt"
- xmlns:ppe="clr-namespace:org.eclipse.papyrus.views.properties.widgets"
- xmlns="http://www.eclipse.org/xwt/presentation" xmlns:j="clr-namespace:java.lang"
- xmlns:ppel="clr-namespace:org.eclipse.papyrus.views.properties.widgets.layout">
- <Composite.layout>
- <ppel:PropertiesLayout></ppel:PropertiesLayout>
- </Composite.layout>
- <Composite>
- <Composite.layout>
- <ppel:PropertiesLayout numColumns="1"></ppel:PropertiesLayout>
- </Composite.layout>
- <ppe:StringEditor input="{Binding}"
- property="UMLRealTime:RTPort:registrationOverride"></ppe:StringEditor>
- </Composite>
- <Composite>
- <Composite.layout>
- <ppel:PropertiesLayout numColumns="2"></ppel:PropertiesLayout>
- </Composite.layout>
- <ppe:BooleanRadio input="{Binding}"
- property="UMLRealTime:RTPort:isNotification"></ppe:BooleanRadio>
- <ppe:BooleanRadio input="{Binding}"
- property="UMLRealTime:RTPort:isPublish"></ppe:BooleanRadio>
- <ppe:BooleanRadio input="{Binding}" property="UMLRealTime:RTPort:isWired"></ppe:BooleanRadio>
- </Composite>
- <Composite>
- <Composite.layout>
- <ppel:PropertiesLayout numColumns="1"></ppel:PropertiesLayout>
- </Composite.layout>
- <ppe:EnumCombo input="{Binding}" property="UMLRealTime:RTPort:registration"></ppe:EnumCombo>
- </Composite>
+<?xml version="1.0" encoding="UTF-8"?>
+<Composite xmlns:x="http://www.eclipse.org/xwt" xmlns="http://www.eclipse.org/xwt/presentation"
+ xmlns:ppe="clr-namespace:org.eclipse.papyrus.views.properties.widgets"
+ xmlns:ppel="clr-namespace:org.eclipse.papyrus.views.properties.widgets.layout"
+ xmlns:j="clr-namespace:java.lang"
+ xmlns:uml-rt="clr-namespace:org.eclipse.papyrusrt.umlrt.tooling.properties.widgets">
+ <Composite.layout>
+ <ppel:PropertiesLayout></ppel:PropertiesLayout>
+ </Composite.layout>
+ <Group text="Kind of Port">
+ <Group.layout>
+ <ppel:PropertiesLayout></ppel:PropertiesLayout>
+ </Group.layout>
+ <ppe:EnumRadio input="{Binding}" property="UMLRealTime:RTPort:kind"></ppe:EnumRadio>
+ </Group>
+ <Group text="UML Properties">
+ <Group.layout>
+ <RowLayout></RowLayout>
+ </Group.layout>
+ <ppe:BooleanCheckbox input="{Binding}"
+ property="UMLRealTimeExt:Port:isBehavior"></ppe:BooleanCheckbox>
+ <ppe:BooleanCheckbox input="{Binding}"
+ property="UMLRealTimeExt:Port:isService"></ppe:BooleanCheckbox>
+ <ppe:BooleanCheckbox input="{Binding}"
+ property="UMLRealTimeExt:Port:isConjugated"></ppe:BooleanCheckbox>
+ </Group>
+ <Group text="Real Time Properties">
+ <Group.layout>
+ <ppel:PropertiesLayout></ppel:PropertiesLayout>
+ </Group.layout>
+ <Composite>
+ <Composite.layout>
+ <RowLayout></RowLayout>
+ </Composite.layout>
+ <ppe:BooleanCheckbox input="{Binding}"
+ property="UMLRealTime:RTPort:isNotification"></ppe:BooleanCheckbox>
+ <ppe:BooleanCheckbox input="{Binding}"
+ property="UMLRealTime:RTPort:isPublish"></ppe:BooleanCheckbox>
+ <ppe:BooleanCheckbox input="{Binding}"
+ property="UMLRealTime:RTPort:isWired"></ppe:BooleanCheckbox>
+ </Composite>
+ <Composite>
+ <Composite.layout>
+ <ppel:PropertiesLayout numColumns="1"></ppel:PropertiesLayout>
+ </Composite.layout>
+ <ppe:StringEditor input="{Binding}"
+ property="UMLRealTime:RTPort:registrationOverride"></ppe:StringEditor>
+ </Composite>
+ <Composite>
+ <Composite.layout>
+ <ppel:PropertiesLayout numColumns="1"></ppel:PropertiesLayout>
+ </Composite.layout>
+ <Composite>
+ <Composite.layout>
+ <ppel:PropertiesLayout numColumns="1"></ppel:PropertiesLayout>
+ </Composite.layout>
+ <ppe:EnumCombo input="{Binding}" property="UMLRealTime:RTPort:registration"></ppe:EnumCombo>
+ </Composite>
+ </Composite>
+ </Group>
</Composite> \ No newline at end of file
diff --git a/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/propertyView/UML-RT/uml-rt.ctx b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/propertyView/UML-RT/uml-rt.ctx
index 643012117..026026a02 100644
--- a/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/propertyView/UML-RT/uml-rt.ctx
+++ b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/propertyView/UML-RT/uml-rt.ctx
@@ -1,189 +1,196 @@
-<?xml version="1.0" encoding="ASCII"?>
-<contexts:Context xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:constraints="http://www.eclipse.org/papyrus/constraints/0.9" xmlns:contexts="http://www.eclipse.org/papyrus/properties/contexts/0.9" xmi:id="_WdNAMPMfEeSMV8TyMaa7Sg" name="UMLRealTime">
- <dependencies href="ppe:/context/org.eclipse.papyrus.uml.properties/Model/UML/UML.ctx#_69QJkKDJEeSZxfCXzZz3-w"/>
- <tabs xmi:id="_WdNAMfMfEeSMV8TyMaa7Sg" label="UMLRealTime" id="umlrealtime" priority="100">
- <sections xmi:id="_WdNAMvMfEeSMV8TyMaa7Sg" name="Single RTConnector" sectionFile="ui/SingleRTConnector.xwt">
- <widget href="ui/SingleRTConnector.xwt#/"/>
- </sections>
- <sections xmi:id="_WdNAM_MfEeSMV8TyMaa7Sg" name="Multiple RTConnector" sectionFile="ui/MultipleRTConnector.xwt">
- <widget href="ui/MultipleRTConnector.xwt#/"/>
- </sections>
- <sections xmi:id="_WdNANPMfEeSMV8TyMaa7Sg" name="Single RTPort" sectionFile="ui/SingleRTPort.xwt">
- <widget href="ui/SingleRTPort.xwt#/"/>
- </sections>
- <sections xmi:id="_WdNANfMfEeSMV8TyMaa7Sg" name="Multiple RTPort" sectionFile="ui/MultipleRTPort.xwt">
- <widget href="ui/MultipleRTPort.xwt#/"/>
- </sections>
- <sections xmi:id="_WdNANvMfEeSMV8TyMaa7Sg" name="Single Capsule" sectionFile="ui/SingleCapsule.xwt">
- <widget href="ui/SingleCapsule.xwt#/"/>
- </sections>
- <sections xmi:id="_WdNAN_MfEeSMV8TyMaa7Sg" name="Multiple Capsule" sectionFile="ui/MultipleCapsule.xwt">
- <widget href="ui/MultipleCapsule.xwt#/"/>
- </sections>
- <sections xmi:id="_WdNAOPMfEeSMV8TyMaa7Sg" name="Single Protocol" sectionFile="ui/SingleProtocol.xwt">
- <widget href="ui/SingleProtocol.xwt#/"/>
- </sections>
- <sections xmi:id="_WdNAOfMfEeSMV8TyMaa7Sg" name="Multiple Protocol" sectionFile="ui/MultipleProtocol.xwt">
- <widget href="ui/MultipleProtocol.xwt#/"/>
- </sections>
- <sections xmi:id="_WdNAOvMfEeSMV8TyMaa7Sg" name="Single RTMessageSet" sectionFile="ui/SingleRTMessageSet.xwt">
- <widget href="ui/SingleRTMessageSet.xwt#/"/>
- </sections>
- <sections xmi:id="_WdNAO_MfEeSMV8TyMaa7Sg" name="Multiple RTMessageSet" sectionFile="ui/MultipleRTMessageSet.xwt">
- <widget href="ui/MultipleRTMessageSet.xwt#/"/>
- </sections>
- <sections xmi:id="_WdNAPPMfEeSMV8TyMaa7Sg" name="Single ProtocolContainer" sectionFile="ui/SingleProtocolContainer.xwt">
- <widget href="ui/SingleProtocolContainer.xwt#/"/>
- </sections>
- <sections xmi:id="_WdNAPfMfEeSMV8TyMaa7Sg" name="Multiple ProtocolContainer" sectionFile="ui/MultipleProtocolContainer.xwt">
- <widget href="ui/MultipleProtocolContainer.xwt#/"/>
- </sections>
- <sections xmi:id="_WdNAPvMfEeSMV8TyMaa7Sg" name="Single CapsulePart" sectionFile="ui/SingleCapsulePart.xwt">
- <widget href="ui/SingleCapsulePart.xwt#/"/>
- </sections>
- <sections xmi:id="_WdNAP_MfEeSMV8TyMaa7Sg" name="Multiple CapsulePart" sectionFile="ui/MultipleCapsulePart.xwt">
- <widget href="ui/MultipleCapsulePart.xwt#/"/>
- </sections>
- <sections xmi:id="_WdNAQPMfEeSMV8TyMaa7Sg" name="Single RTRExcludedElement" sectionFile="ui/SingleRTRExcludedElement.xwt">
- <widget href="ui/SingleRTRExcludedElement.xwt#/"/>
- </sections>
- <sections xmi:id="_WdNAQfMfEeSMV8TyMaa7Sg" name="Multiple RTRExcludedElement" sectionFile="ui/MultipleRTRExcludedElement.xwt">
- <widget href="ui/MultipleRTRExcludedElement.xwt#/"/>
- </sections>
- </tabs>
- <views xmi:id="_WdNAQvMfEeSMV8TyMaa7Sg" name="Single RTConnector" sections="_WdNAMvMfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNnafMfEeSMV8TyMaa7Sg">
- <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNAQ_MfEeSMV8TyMaa7Sg" name="isSingleRTConnector">
- <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
- <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNARPMfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::RTConnector"/>
- </constraints>
- </views>
- <views xmi:id="_WdNARfMfEeSMV8TyMaa7Sg" elementMultiplicity="-1" name="Multiple RTConnector" sections="_WdNAM_MfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNnafMfEeSMV8TyMaa7Sg">
- <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNARvMfEeSMV8TyMaa7Sg" name="isMultipleRTConnector">
- <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
- <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNAR_MfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::RTConnector"/>
- </constraints>
- </views>
- <views xmi:id="_WdNASPMfEeSMV8TyMaa7Sg" name="Single RTPort" sections="_WdNANPMfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNnY_MfEeSMV8TyMaa7Sg">
- <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNASfMfEeSMV8TyMaa7Sg" name="isSingleRTPort">
- <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
- <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNASvMfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::RTPort"/>
- </constraints>
- </views>
- <views xmi:id="_WdNAS_MfEeSMV8TyMaa7Sg" elementMultiplicity="-1" name="Multiple RTPort" sections="_WdNANfMfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNnY_MfEeSMV8TyMaa7Sg">
- <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNATPMfEeSMV8TyMaa7Sg" name="isMultipleRTPort">
- <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
- <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNATfMfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::RTPort"/>
- </constraints>
- </views>
- <views xmi:id="_WdNATvMfEeSMV8TyMaa7Sg" name="Single Capsule" sections="_WdNANvMfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNnbfMfEeSMV8TyMaa7Sg">
- <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNAT_MfEeSMV8TyMaa7Sg" name="isSingleCapsule">
- <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
- <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNnQPMfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::Capsule"/>
- </constraints>
- </views>
- <views xmi:id="_WdNnQfMfEeSMV8TyMaa7Sg" elementMultiplicity="-1" name="Multiple Capsule" sections="_WdNAN_MfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNnbfMfEeSMV8TyMaa7Sg">
- <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNnQvMfEeSMV8TyMaa7Sg" name="isMultipleCapsule">
- <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
- <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNnQ_MfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::Capsule"/>
- </constraints>
- </views>
- <views xmi:id="_WdNnRPMfEeSMV8TyMaa7Sg" name="Single Protocol" sections="_WdNAOPMfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNncfMfEeSMV8TyMaa7Sg">
- <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNnRfMfEeSMV8TyMaa7Sg" name="isSingleProtocol">
- <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
- <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNnRvMfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::Protocol"/>
- </constraints>
- </views>
- <views xmi:id="_WdNnR_MfEeSMV8TyMaa7Sg" elementMultiplicity="-1" name="Multiple Protocol" sections="_WdNAOfMfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNncfMfEeSMV8TyMaa7Sg">
- <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNnSPMfEeSMV8TyMaa7Sg" name="isMultipleProtocol">
- <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
- <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNnSfMfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::Protocol"/>
- </constraints>
- </views>
- <views xmi:id="_WdNnSvMfEeSMV8TyMaa7Sg" name="Single RTMessageSet" sections="_WdNAOvMfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNnbvMfEeSMV8TyMaa7Sg">
- <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNnS_MfEeSMV8TyMaa7Sg" name="isSingleRTMessageSet">
- <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
- <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNnTPMfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::RTMessageSet"/>
- </constraints>
- </views>
- <views xmi:id="_WdNnTfMfEeSMV8TyMaa7Sg" elementMultiplicity="-1" name="Multiple RTMessageSet" sections="_WdNAO_MfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNnbvMfEeSMV8TyMaa7Sg">
- <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNnTvMfEeSMV8TyMaa7Sg" name="isMultipleRTMessageSet">
- <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
- <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNnT_MfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::RTMessageSet"/>
- </constraints>
- </views>
- <views xmi:id="_WdNnUPMfEeSMV8TyMaa7Sg" name="Single ProtocolContainer" sections="_WdNAPPMfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNna_MfEeSMV8TyMaa7Sg">
- <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNnUfMfEeSMV8TyMaa7Sg" name="isSingleProtocolContainer">
- <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
- <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNnUvMfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::ProtocolContainer"/>
- </constraints>
- </views>
- <views xmi:id="_WdNnU_MfEeSMV8TyMaa7Sg" elementMultiplicity="-1" name="Multiple ProtocolContainer" sections="_WdNAPfMfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNna_MfEeSMV8TyMaa7Sg">
- <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNnVPMfEeSMV8TyMaa7Sg" name="isMultipleProtocolContainer">
- <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
- <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNnVfMfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::ProtocolContainer"/>
- </constraints>
- </views>
- <views xmi:id="_WdNnVvMfEeSMV8TyMaa7Sg" name="Single CapsulePart" sections="_WdNAPvMfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNnavMfEeSMV8TyMaa7Sg">
- <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNnV_MfEeSMV8TyMaa7Sg" name="isSingleCapsulePart">
- <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
- <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNnWPMfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::CapsulePart"/>
- </constraints>
- </views>
- <views xmi:id="_WdNnWfMfEeSMV8TyMaa7Sg" elementMultiplicity="-1" name="Multiple CapsulePart" sections="_WdNAP_MfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNnavMfEeSMV8TyMaa7Sg">
- <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNnWvMfEeSMV8TyMaa7Sg" name="isMultipleCapsulePart">
- <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
- <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNnW_MfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::CapsulePart"/>
- </constraints>
- </views>
- <views xmi:id="_WdNnXPMfEeSMV8TyMaa7Sg" name="Single RTRExcludedElement" sections="_WdNAQPMfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNnbPMfEeSMV8TyMaa7Sg">
- <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNnXfMfEeSMV8TyMaa7Sg" name="isSingleRTRExcludedElement">
- <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
- <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNnXvMfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::RTRExcludedElement"/>
- </constraints>
- </views>
- <views xmi:id="_WdNnX_MfEeSMV8TyMaa7Sg" elementMultiplicity="-1" name="Multiple RTRExcludedElement" sections="_WdNAQfMfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNnbPMfEeSMV8TyMaa7Sg">
- <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNnYPMfEeSMV8TyMaa7Sg" name="isMultipleRTRExcludedElement">
- <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
- <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNnYfMfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::RTRExcludedElement"/>
- </constraints>
- </views>
- <dataContexts xmi:id="_WdNnYvMfEeSMV8TyMaa7Sg" name="UMLRealTime">
- <elements xmi:id="_WdNnY_MfEeSMV8TyMaa7Sg" name="RTPort">
- <properties xmi:id="_WdNnZPMfEeSMV8TyMaa7Sg" name="isNotification" type="Boolean"/>
- <properties xmi:id="_WdNnZfMfEeSMV8TyMaa7Sg" name="isPublish" type="Boolean"/>
- <properties xmi:id="_WdNnZvMfEeSMV8TyMaa7Sg" name="isWired" type="Boolean"/>
- <properties xmi:id="_WdNnZ_MfEeSMV8TyMaa7Sg" name="registration" type="Enumeration"/>
- <properties xmi:id="_WdNnaPMfEeSMV8TyMaa7Sg" name="registrationOverride"/>
- <supertypes href="ppe:/context/org.eclipse.papyrus.uml.properties/Model/UML/UML.ctx#//@dataContexts.0/@elements.58"/>
- </elements>
- <elements xmi:id="_WdNnafMfEeSMV8TyMaa7Sg" name="RTConnector">
- <supertypes href="ppe:/context/org.eclipse.papyrus.uml.properties/Model/UML/UML.ctx#//@dataContexts.0/@elements.65"/>
- </elements>
- <elements xmi:id="_WdNnavMfEeSMV8TyMaa7Sg" name="CapsulePart">
- <supertypes href="ppe:/context/org.eclipse.papyrus.uml.properties/Model/UML/UML.ctx#//@dataContexts.0/@elements.35"/>
- </elements>
- <elements xmi:id="_WdNna_MfEeSMV8TyMaa7Sg" name="ProtocolContainer">
- <supertypes href="ppe:/context/org.eclipse.papyrus.uml.properties/Model/UML/UML.ctx#//@dataContexts.0/@elements.2"/>
- </elements>
- <elements xmi:id="_WdNnbPMfEeSMV8TyMaa7Sg" name="RTRExcludedElement">
- <supertypes href="ppe:/context/org.eclipse.papyrus.uml.properties/Model/UML/UML.ctx#//@dataContexts.0/@elements.17"/>
- </elements>
- <elements xmi:id="_WdNnbfMfEeSMV8TyMaa7Sg" name="Capsule">
- <supertypes href="ppe:/context/org.eclipse.papyrus.uml.properties/Model/UML/UML.ctx#//@dataContexts.0/@elements.45"/>
- </elements>
- <elements xmi:id="_WdNnbvMfEeSMV8TyMaa7Sg" name="RTMessageSet">
- <properties xmi:id="_WdNnb_MfEeSMV8TyMaa7Sg" name="rtMsgKind" type="Enumeration"/>
- <supertypes href="ppe:/context/org.eclipse.papyrus.uml.properties/Model/UML/UML.ctx#//@dataContexts.0/@elements.48"/>
- </elements>
- <modelElementFactory href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@modelElementFactories.2"/>
- </dataContexts>
- <dataContexts xmi:id="_WdNncPMfEeSMV8TyMaa7Sg" name="UMLRealTimeExt">
- <elements xmi:id="_WdNncfMfEeSMV8TyMaa7Sg" name="Protocol">
- <properties xmi:id="_WdNncvMfEeSMV8TyMaa7Sg" name="provides" type="Reference"/>
- <properties xmi:id="_WdNnc_MfEeSMV8TyMaa7Sg" name="required" type="Reference"/>
- <properties xmi:id="_WdNndPMfEeSMV8TyMaa7Sg" name="provreq" type="Reference"/>
- <supertypes href="ppe:/context/org.eclipse.papyrus.uml.properties/Model/UML/UML.ctx#//@dataContexts.0/@elements.78"/>
- </elements>
- <modelElementFactory href="ppe:/environment/org.eclipse.papyrusrt.umlrt.tooling.properties/propertyView/UML-RT/Environment.xmi#//@modelElementFactories.0"/>
- </dataContexts>
-</contexts:Context>
+<?xml version="1.0" encoding="ASCII"?>
+<contexts:Context xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:constraints="http://www.eclipse.org/papyrus/constraints/0.9" xmlns:contexts="http://www.eclipse.org/papyrus/properties/contexts/0.9" xmi:id="_WdNAMPMfEeSMV8TyMaa7Sg" name="UMLRealTime">
+ <dependencies href="ppe:/context/org.eclipse.papyrus.uml.properties/Model/UML/UML.ctx#_69QJkKDJEeSZxfCXzZz3-w"/>
+ <tabs xmi:id="_WdNAMfMfEeSMV8TyMaa7Sg" label="UMLRealTime" id="umlrealtime" priority="100">
+ <sections xmi:id="_WdNAMvMfEeSMV8TyMaa7Sg" name="Single RTConnector" sectionFile="ui/SingleRTConnector.xwt">
+ <widget href="ui/SingleRTConnector.xwt#/"/>
+ </sections>
+ <sections xmi:id="_WdNAM_MfEeSMV8TyMaa7Sg" name="Multiple RTConnector" sectionFile="ui/MultipleRTConnector.xwt">
+ <widget href="ui/MultipleRTConnector.xwt#/"/>
+ </sections>
+ <sections xmi:id="_WdNANPMfEeSMV8TyMaa7Sg" name="Single RTPort" sectionFile="ui/SingleRTPort.xwt">
+ <widget href="ui/SingleRTPort.xwt#/"/>
+ </sections>
+ <sections xmi:id="_WdNANfMfEeSMV8TyMaa7Sg" name="Multiple RTPort" sectionFile="ui/MultipleRTPort.xwt">
+ <widget href="ui/MultipleRTPort.xwt#/"/>
+ </sections>
+ <sections xmi:id="_WdNANvMfEeSMV8TyMaa7Sg" name="Single Capsule" sectionFile="ui/SingleCapsule.xwt">
+ <widget href="ui/SingleCapsule.xwt#/"/>
+ </sections>
+ <sections xmi:id="_WdNAN_MfEeSMV8TyMaa7Sg" name="Multiple Capsule" sectionFile="ui/MultipleCapsule.xwt">
+ <widget href="ui/MultipleCapsule.xwt#/"/>
+ </sections>
+ <sections xmi:id="_WdNAOPMfEeSMV8TyMaa7Sg" name="Single Protocol" sectionFile="ui/SingleProtocol.xwt">
+ <widget href="ui/SingleProtocol.xwt#/"/>
+ </sections>
+ <sections xmi:id="_WdNAOfMfEeSMV8TyMaa7Sg" name="Multiple Protocol" sectionFile="ui/MultipleProtocol.xwt">
+ <widget href="ui/MultipleProtocol.xwt#/"/>
+ </sections>
+ <sections xmi:id="_WdNAOvMfEeSMV8TyMaa7Sg" name="Single RTMessageSet" sectionFile="ui/SingleRTMessageSet.xwt">
+ <widget href="ui/SingleRTMessageSet.xwt#/"/>
+ </sections>
+ <sections xmi:id="_WdNAO_MfEeSMV8TyMaa7Sg" name="Multiple RTMessageSet" sectionFile="ui/MultipleRTMessageSet.xwt">
+ <widget href="ui/MultipleRTMessageSet.xwt#/"/>
+ </sections>
+ <sections xmi:id="_WdNAPPMfEeSMV8TyMaa7Sg" name="Single ProtocolContainer" sectionFile="ui/SingleProtocolContainer.xwt">
+ <widget href="ui/SingleProtocolContainer.xwt#/"/>
+ </sections>
+ <sections xmi:id="_WdNAPfMfEeSMV8TyMaa7Sg" name="Multiple ProtocolContainer" sectionFile="ui/MultipleProtocolContainer.xwt">
+ <widget href="ui/MultipleProtocolContainer.xwt#/"/>
+ </sections>
+ <sections xmi:id="_WdNAPvMfEeSMV8TyMaa7Sg" name="Single CapsulePart" sectionFile="ui/SingleCapsulePart.xwt">
+ <widget href="ui/SingleCapsulePart.xwt#/"/>
+ </sections>
+ <sections xmi:id="_WdNAP_MfEeSMV8TyMaa7Sg" name="Multiple CapsulePart" sectionFile="ui/MultipleCapsulePart.xwt">
+ <widget href="ui/MultipleCapsulePart.xwt#/"/>
+ </sections>
+ <sections xmi:id="_WdNAQPMfEeSMV8TyMaa7Sg" name="Single RTRExcludedElement" sectionFile="ui/SingleRTRExcludedElement.xwt">
+ <widget href="ui/SingleRTRExcludedElement.xwt#/"/>
+ </sections>
+ <sections xmi:id="_WdNAQfMfEeSMV8TyMaa7Sg" name="Multiple RTRExcludedElement" sectionFile="ui/MultipleRTRExcludedElement.xwt">
+ <widget href="ui/MultipleRTRExcludedElement.xwt#/"/>
+ </sections>
+ </tabs>
+ <views xmi:id="_WdNAQvMfEeSMV8TyMaa7Sg" name="Single RTConnector" sections="_WdNAMvMfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNnafMfEeSMV8TyMaa7Sg">
+ <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNAQ_MfEeSMV8TyMaa7Sg" name="isSingleRTConnector">
+ <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
+ <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNARPMfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::RTConnector"/>
+ </constraints>
+ </views>
+ <views xmi:id="_WdNARfMfEeSMV8TyMaa7Sg" elementMultiplicity="-1" name="Multiple RTConnector" sections="_WdNAM_MfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNnafMfEeSMV8TyMaa7Sg">
+ <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNARvMfEeSMV8TyMaa7Sg" name="isMultipleRTConnector">
+ <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
+ <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNAR_MfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::RTConnector"/>
+ </constraints>
+ </views>
+ <views xmi:id="_WdNASPMfEeSMV8TyMaa7Sg" name="Single RTPort" sections="_WdNANPMfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNnY_MfEeSMV8TyMaa7Sg">
+ <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNASfMfEeSMV8TyMaa7Sg" name="isSingleRTPort">
+ <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
+ <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNASvMfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::RTPort"/>
+ </constraints>
+ </views>
+ <views xmi:id="_WdNAS_MfEeSMV8TyMaa7Sg" elementMultiplicity="-1" name="Multiple RTPort" sections="_WdNANfMfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNnY_MfEeSMV8TyMaa7Sg">
+ <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNATPMfEeSMV8TyMaa7Sg" name="isMultipleRTPort">
+ <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
+ <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNATfMfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::RTPort"/>
+ </constraints>
+ </views>
+ <views xmi:id="_WdNATvMfEeSMV8TyMaa7Sg" name="Single Capsule" sections="_WdNANvMfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNnbfMfEeSMV8TyMaa7Sg">
+ <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNAT_MfEeSMV8TyMaa7Sg" name="isSingleCapsule">
+ <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
+ <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNnQPMfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::Capsule"/>
+ </constraints>
+ </views>
+ <views xmi:id="_WdNnQfMfEeSMV8TyMaa7Sg" elementMultiplicity="-1" name="Multiple Capsule" sections="_WdNAN_MfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNnbfMfEeSMV8TyMaa7Sg">
+ <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNnQvMfEeSMV8TyMaa7Sg" name="isMultipleCapsule">
+ <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
+ <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNnQ_MfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::Capsule"/>
+ </constraints>
+ </views>
+ <views xmi:id="_WdNnRPMfEeSMV8TyMaa7Sg" name="Single Protocol" sections="_WdNAOPMfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNncfMfEeSMV8TyMaa7Sg">
+ <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNnRfMfEeSMV8TyMaa7Sg" name="isSingleProtocol">
+ <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
+ <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNnRvMfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::Protocol"/>
+ </constraints>
+ </views>
+ <views xmi:id="_WdNnR_MfEeSMV8TyMaa7Sg" elementMultiplicity="-1" name="Multiple Protocol" sections="_WdNAOfMfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNncfMfEeSMV8TyMaa7Sg">
+ <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNnSPMfEeSMV8TyMaa7Sg" name="isMultipleProtocol">
+ <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
+ <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNnSfMfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::Protocol"/>
+ </constraints>
+ </views>
+ <views xmi:id="_WdNnSvMfEeSMV8TyMaa7Sg" name="Single RTMessageSet" sections="_WdNAOvMfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNnbvMfEeSMV8TyMaa7Sg">
+ <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNnS_MfEeSMV8TyMaa7Sg" name="isSingleRTMessageSet">
+ <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
+ <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNnTPMfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::RTMessageSet"/>
+ </constraints>
+ </views>
+ <views xmi:id="_WdNnTfMfEeSMV8TyMaa7Sg" elementMultiplicity="-1" name="Multiple RTMessageSet" sections="_WdNAO_MfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNnbvMfEeSMV8TyMaa7Sg">
+ <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNnTvMfEeSMV8TyMaa7Sg" name="isMultipleRTMessageSet">
+ <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
+ <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNnT_MfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::RTMessageSet"/>
+ </constraints>
+ </views>
+ <views xmi:id="_WdNnUPMfEeSMV8TyMaa7Sg" name="Single ProtocolContainer" sections="_WdNAPPMfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNna_MfEeSMV8TyMaa7Sg">
+ <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNnUfMfEeSMV8TyMaa7Sg" name="isSingleProtocolContainer">
+ <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
+ <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNnUvMfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::ProtocolContainer"/>
+ </constraints>
+ </views>
+ <views xmi:id="_WdNnU_MfEeSMV8TyMaa7Sg" elementMultiplicity="-1" name="Multiple ProtocolContainer" sections="_WdNAPfMfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNna_MfEeSMV8TyMaa7Sg">
+ <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNnVPMfEeSMV8TyMaa7Sg" name="isMultipleProtocolContainer">
+ <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
+ <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNnVfMfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::ProtocolContainer"/>
+ </constraints>
+ </views>
+ <views xmi:id="_WdNnVvMfEeSMV8TyMaa7Sg" name="Single CapsulePart" sections="_WdNAPvMfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNnavMfEeSMV8TyMaa7Sg">
+ <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNnV_MfEeSMV8TyMaa7Sg" name="isSingleCapsulePart">
+ <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
+ <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNnWPMfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::CapsulePart"/>
+ </constraints>
+ </views>
+ <views xmi:id="_WdNnWfMfEeSMV8TyMaa7Sg" elementMultiplicity="-1" name="Multiple CapsulePart" sections="_WdNAP_MfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNnavMfEeSMV8TyMaa7Sg">
+ <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNnWvMfEeSMV8TyMaa7Sg" name="isMultipleCapsulePart">
+ <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
+ <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNnW_MfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::CapsulePart"/>
+ </constraints>
+ </views>
+ <views xmi:id="_WdNnXPMfEeSMV8TyMaa7Sg" name="Single RTRExcludedElement" sections="_WdNAQPMfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNnbPMfEeSMV8TyMaa7Sg">
+ <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNnXfMfEeSMV8TyMaa7Sg" name="isSingleRTRExcludedElement">
+ <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
+ <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNnXvMfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::RTRExcludedElement"/>
+ </constraints>
+ </views>
+ <views xmi:id="_WdNnX_MfEeSMV8TyMaa7Sg" elementMultiplicity="-1" name="Multiple RTRExcludedElement" sections="_WdNAQfMfEeSMV8TyMaa7Sg" automaticContext="true" datacontexts="_WdNnbPMfEeSMV8TyMaa7Sg">
+ <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_WdNnYPMfEeSMV8TyMaa7Sg" name="isMultipleRTRExcludedElement">
+ <constraintType href="ppe:/environment/org.eclipse.papyrus.uml.properties/Model/Environment.xmi#//@constraintTypes.1"/>
+ <properties xsi:type="constraints:ValueProperty" xmi:id="_WdNnYfMfEeSMV8TyMaa7Sg" name="stereotypeName" value="UMLRealTime::RTRExcludedElement"/>
+ </constraints>
+ </views>
+ <dataContexts xmi:id="_WdNnYvMfEeSMV8TyMaa7Sg" name="UMLRealTime">
+ <elements xmi:id="_WdNnY_MfEeSMV8TyMaa7Sg" name="RTPort">
+ <properties xmi:id="_WdNnZPMfEeSMV8TyMaa7Sg" name="isNotification" type="Boolean"/>
+ <properties xmi:id="_WdNnZfMfEeSMV8TyMaa7Sg" name="isPublish" type="Boolean"/>
+ <properties xmi:id="_WdNnZvMfEeSMV8TyMaa7Sg" name="isWired" type="Boolean"/>
+ <properties xmi:id="_WdNnZ_MfEeSMV8TyMaa7Sg" name="registration" type="Enumeration" description=""/>
+ <properties xmi:id="_WdNnaPMfEeSMV8TyMaa7Sg" name="registrationOverride" description=""/>
+ <properties xmi:id="_QhkXQC6_EeWWx70qeJ-t-Q" name="kind" label="" type="Enumeration" description=""/>
+ <supertypes href="ppe:/context/org.eclipse.papyrus.uml.properties/Model/UML/UML.ctx#_690ylaDJEeSZxfCXzZz3-w"/>
+ </elements>
+ <elements xmi:id="_WdNnafMfEeSMV8TyMaa7Sg" name="RTConnector">
+ <supertypes href="ppe:/context/org.eclipse.papyrus.uml.properties/Model/UML/UML.ctx#_690yvqDJEeSZxfCXzZz3-w"/>
+ </elements>
+ <elements xmi:id="_WdNnavMfEeSMV8TyMaa7Sg" name="CapsulePart">
+ <properties xmi:id="_lozRECyNEeWRyc_Z_MwFYQ" name="type" label="" type="Enumeration" description=""/>
+ <properties xmi:id="_Wr_eECyOEeWRyc_Z_MwFYQ" name="multiplicity" type="Integer"/>
+ <properties xmi:id="_XE4fMCyOEeWRyc_Z_MwFYQ" name="aggregation" type="Enumeration"/>
+ <supertypes href="ppe:/context/org.eclipse.papyrus.uml.properties/Model/UML/UML.ctx#_690yG6DJEeSZxfCXzZz3-w"/>
+ </elements>
+ <elements xmi:id="_WdNna_MfEeSMV8TyMaa7Sg" name="ProtocolContainer">
+ <supertypes href="ppe:/context/org.eclipse.papyrus.uml.properties/Model/UML/UML.ctx#_690xiaDJEeSZxfCXzZz3-w"/>
+ </elements>
+ <elements xmi:id="_WdNnbPMfEeSMV8TyMaa7Sg" name="RTRExcludedElement">
+ <supertypes href="ppe:/context/org.eclipse.papyrus.uml.properties/Model/UML/UML.ctx#//@dataContexts.0/@elements.17"/>
+ </elements>
+ <elements xmi:id="_WdNnbfMfEeSMV8TyMaa7Sg" name="Capsule">
+ <supertypes href="ppe:/context/org.eclipse.papyrus.uml.properties/Model/UML/UML.ctx#_690yXqDJEeSZxfCXzZz3-w"/>
+ </elements>
+ <elements xmi:id="_WdNnbvMfEeSMV8TyMaa7Sg" name="RTMessageSet">
+ <properties xmi:id="_WdNnb_MfEeSMV8TyMaa7Sg" name="rtMsgKind" type="Enumeration"/>
+ <supertypes href="ppe:/context/org.eclipse.papyrus.uml.properties/Model/UML/UML.ctx#//@dataContexts.0/@elements.48"/>
+ </elements>
+ <modelElementFactory href="ppe:/environment/org.eclipse.papyrusrt.umlrt.tooling.properties/propertyView/UML-RT/Environment.xmi#//@modelElementFactories.1"/>
+ </dataContexts>
+ <dataContexts xmi:id="_WdNncPMfEeSMV8TyMaa7Sg" name="UMLRealTimeExt">
+ <elements xmi:id="_WdNncfMfEeSMV8TyMaa7Sg" name="Protocol">
+ <properties xmi:id="_WdNncvMfEeSMV8TyMaa7Sg" name="provides" type="Reference"/>
+ <properties xmi:id="_WdNnc_MfEeSMV8TyMaa7Sg" name="required" type="Reference"/>
+ <properties xmi:id="_WdNndPMfEeSMV8TyMaa7Sg" name="provreq" type="Reference"/>
+ <supertypes href="ppe:/context/org.eclipse.papyrus.uml.properties/Model/UML/UML.ctx#_690y4KDJEeSZxfCXzZz3-w"/>
+ </elements>
+ <elements xmi:id="_SIdvoDIMEeWNUrU2mjUBfw" name="Port">
+ <supertypes href="ppe:/context/org.eclipse.papyrus.uml.properties/Model/UML/UML.ctx#_690ylaDJEeSZxfCXzZz3-w"/>
+ </elements>
+ <modelElementFactory href="ppe:/environment/org.eclipse.papyrusrt.umlrt.tooling.properties/propertyView/UML-RT/Environment.xmi#//@modelElementFactories.0"/>
+ </dataContexts>
+</contexts:Context>
diff --git a/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/modelelement/RTStereotypeModelElement.java b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/modelelement/RTStereotypeModelElement.java
new file mode 100644
index 000000000..e221f5e6b
--- /dev/null
+++ b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/modelelement/RTStereotypeModelElement.java
@@ -0,0 +1,116 @@
+/*****************************************************************************
+ * Copyright (c) 2010, 2015 CEA LIST and others.
+ *
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Celine JANSSENS (ALL4TEC) celine.janssens@all4tec.net - Initial API and implementation
+ *
+ *****************************************************************************/
+
+package org.eclipse.papyrusrt.umlrt.tooling.properties.modelelement;
+
+import java.util.HashMap;
+import java.util.Map;
+
+import org.eclipse.core.databinding.observable.IObservable;
+import org.eclipse.emf.ecore.EObject;
+import org.eclipse.emf.edit.domain.EditingDomain;
+import org.eclipse.emf.transaction.TransactionalEditingDomain;
+import org.eclipse.papyrus.infra.widgets.providers.IStaticContentProvider;
+import org.eclipse.papyrus.infra.widgets.providers.StaticContentProvider;
+import org.eclipse.papyrus.uml.properties.modelelement.StereotypeModelElement;
+import org.eclipse.papyrusrt.umlrt.tooling.properties.util.Constants;
+import org.eclipse.papyrusrt.umlrt.tooling.properties.util.RTPortHelper;
+import org.eclipse.papyrusrt.umlrt.tooling.properties.widgets.PortRTKindEnum;
+import org.eclipse.papyrusrt.umlrt.tooling.properties.widgets.PortRTKindObservableValue;
+import org.eclipse.uml2.uml.Port;
+import org.eclipse.uml2.uml.Stereotype;
+import org.eclipse.uml2.uml.util.UMLUtil;
+
+public class RTStereotypeModelElement extends StereotypeModelElement {
+
+
+ private EObject stereoApplication;
+ private RTPortHelper portHelper = RTPortHelper.getInstance();
+
+
+
+ public RTStereotypeModelElement(final EObject stereoApplication, final Stereotype stereotype, final EditingDomain domain) {
+ super(stereoApplication, stereotype, domain);
+ this.stereoApplication = stereoApplication;
+
+ }
+
+ @Override
+ protected boolean isFeatureEditable(final String propertyPath) {
+ boolean editable = true;
+ Object source = UMLUtil.getBaseElement(stereoApplication);
+
+ if (source instanceof Port) {
+ Port port = (Port) source;
+ if (Constants.KIND.equals(propertyPath)) {
+ editable = true;
+ } else if (Constants.NOTIFICATION.equals(propertyPath)) {
+ editable = true; // TODO: This method is not updated when values are changed (good value would be when portHelper.isBehavior(port);)
+ } else if (Constants.WIRED.equals(propertyPath)) {
+ editable = true; // TODO: This method is not updated when values are changed (good value would be when portHelper.isBehavior(port) || portHelper.isConnected(port);)
+ } else if (Constants.PUBLISH.equals(propertyPath)) {
+ editable = false;
+ }
+ } else {
+
+ editable = super.isFeatureEditable(propertyPath);
+ }
+ return editable;
+ }
+
+
+ @Override
+ public IObservable doGetObservable(final String propertyPath) {
+ IObservable observe = null;
+
+ // Case of Kind value in the Port RT Property View
+ if (Constants.KIND.equals(propertyPath)) {
+ observe = new PortRTKindObservableValue(UMLUtil.getBaseElement(stereoApplication), (TransactionalEditingDomain) domain);
+ } else {
+ observe = super.doGetObservable(propertyPath);
+ }
+ return observe;
+
+ }
+
+
+ /**
+ * The ContentProvider provide the Map of the Enum value, and there Label to the EnumRadio Editor.
+ *
+ * @see org.eclipse.papyrus.uml.properties.modelelement.StereotypeModelElement#getContentProvider(java.lang.String)
+ *
+ * @param propertyPath
+ * @return
+ */
+ @Override
+ public IStaticContentProvider getContentProvider(String propertyPath) {
+
+ IStaticContentProvider provider = null;
+ if (Constants.KIND.equals(propertyPath)) {
+ Map<Object, String> map = new HashMap<Object, String>();
+
+ map.put(PortRTKindEnum.EXTERNAL, PortRTKindEnum.EXTERNAL.getLabel());
+ map.put(PortRTKindEnum.INTERNAL, PortRTKindEnum.INTERNAL.getLabel());
+ map.put(PortRTKindEnum.RELAY, PortRTKindEnum.RELAY.getLabel());
+ map.put(PortRTKindEnum.SAP, PortRTKindEnum.SAP.getLabel());
+ map.put(PortRTKindEnum.SPP, PortRTKindEnum.SPP.getLabel());
+
+ provider = new StaticContentProvider(map.keySet().toArray());
+
+ } else {
+ provider = super.getContentProvider(propertyPath);
+ }
+ return provider;
+ }
+
+}
diff --git a/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/modelelement/RTStereotypeModelElementFactory.java b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/modelelement/RTStereotypeModelElementFactory.java
new file mode 100644
index 000000000..ed4d4113c
--- /dev/null
+++ b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/modelelement/RTStereotypeModelElementFactory.java
@@ -0,0 +1,61 @@
+/*****************************************************************************
+ * Copyright (c) 2010, 2015 CEA LIST and others.
+ *
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Celine JANSSENS (ALL4TEC) celine.janssens@all4tec.net - Initial API and implementation
+ *
+ *****************************************************************************/
+package org.eclipse.papyrusrt.umlrt.tooling.properties.modelelement;
+
+import org.eclipse.emf.ecore.EObject;
+import org.eclipse.papyrus.infra.emf.utils.EMFHelper;
+import org.eclipse.papyrus.uml.properties.modelelement.StereotypeModelElementFactory;
+import org.eclipse.papyrus.uml.tools.utils.UMLUtil;
+import org.eclipse.papyrus.views.properties.contexts.DataContextElement;
+import org.eclipse.papyrus.views.properties.modelelement.EMFModelElement;
+import org.eclipse.papyrusrt.umlrt.tooling.properties.Activator;
+import org.eclipse.uml2.uml.Element;
+import org.eclipse.uml2.uml.Stereotype;
+
+public class RTStereotypeModelElementFactory extends StereotypeModelElementFactory {
+
+ private static final String UML_REAL_TIME = "UMLRealTime"; // $NON-NLS-0$
+
+ @Override
+ protected EMFModelElement doCreateFromSource(Object sourceElement, DataContextElement context) {
+
+ Element umlElement = UMLUtil.resolveUMLElement(sourceElement);
+
+ EMFModelElement modelElement = null;
+ if (umlElement != null) {
+ Stereotype stereotype = UMLUtil.getAppliedSuperstereotype(umlElement, getQualifiedName(context));
+ Stereotype actual = (stereotype == null) ? null : UMLUtil.getAppliedSubstereotype(umlElement, stereotype);
+ EObject stereotypeApplication = (actual == null) ? null : umlElement.getStereotypeApplication(actual);
+
+ if (null == stereotypeApplication) {
+ Activator.log.warn("Stereotype " + getQualifiedName(context) + " is not applied on " + umlElement); //$NON-NLS-1$ //$NON-NLS-2$
+ } else {
+ // check if we are in the Real Time case
+ if (umlElement instanceof Element && null != stereotype && UML_REAL_TIME.equals(stereotype.getProfile().getName())) {
+ modelElement = new RTStereotypeModelElement(stereotypeApplication, stereotype, EMFHelper.resolveEditingDomain(sourceElement));
+ } else {
+ modelElement = super.doCreateFromSource(umlElement, context);
+ }
+ }
+ }
+
+
+
+ return modelElement;
+ }
+
+
+
+
+
+}
diff --git a/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/modelelement/UMLRTExtModelElement.java b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/modelelement/UMLRTExtModelElement.java
index 48a406b7b..6b21c39f8 100644
--- a/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/modelelement/UMLRTExtModelElement.java
+++ b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/modelelement/UMLRTExtModelElement.java
@@ -27,12 +27,15 @@ import org.eclipse.papyrus.infra.widgets.providers.IStaticContentProvider;
import org.eclipse.papyrus.uml.properties.modelelement.UMLModelElement;
import org.eclipse.papyrusrt.umlrt.profile.UMLRealTime.RTMessageKind;
import org.eclipse.papyrusrt.umlrt.profile.UMLRealTime.RTMessageSet;
+import org.eclipse.papyrusrt.umlrt.tooling.properties.util.Constants;
+import org.eclipse.papyrusrt.umlrt.tooling.properties.util.RTPortHelper;
import org.eclipse.uml2.uml.Collaboration;
import org.eclipse.uml2.uml.Dependency;
import org.eclipse.uml2.uml.DirectedRelationship;
import org.eclipse.uml2.uml.Element;
import org.eclipse.uml2.uml.Interface;
import org.eclipse.uml2.uml.NamedElement;
+import org.eclipse.uml2.uml.Port;
import org.eclipse.uml2.uml.util.UMLUtil;
/**
@@ -42,15 +45,25 @@ import org.eclipse.uml2.uml.util.UMLUtil;
*/
public class UMLRTExtModelElement extends UMLModelElement {
+
+
private Hashtable<Element, UMLModelElement> delegationModelElements;
private final String ownedOp = "ownedOperation"; //$NON-NLS-1$
+ private RTPortHelper portHelper = RTPortHelper.getInstance();
+
+
+ /**
+ * Constructor.
+ */
public UMLRTExtModelElement(EObject source) {
super(source, TransactionUtil.getEditingDomain(source));
delegationModelElements = new Hashtable<Element, UMLModelElement>();
+
}
+
/**
* Get the delegating model element
*
@@ -122,15 +135,20 @@ public class UMLRTExtModelElement extends UMLModelElement {
@Override
public IObservable doGetObservable(String propertyPath) {
+ IObservable observable = null;
+
Interface intf = getProvidedOrRequiredInterface(propertyPath);
if (intf != null) {
- return getDelegationModelElement(intf).doGetObservable(ownedOp);
+ observable = getDelegationModelElement(intf).doGetObservable(ownedOp);
+ } else {
+ observable = super.doGetObservable(propertyPath);
}
- return super.doGetObservable(propertyPath);
+ return observable;
}
@Override
public ReferenceValueFactory getValueFactory(String propertyPath) {
+
Interface intf = getProvidedOrRequiredInterface(propertyPath);
if (intf != null) {
return getDelegationModelElement(intf).getValueFactory(ownedOp);
@@ -158,39 +176,75 @@ public class UMLRTExtModelElement extends UMLModelElement {
return result;
}
+ @Override
+ protected boolean isFeatureEditable(String propertyPath) {
+ boolean editable = false;
+ if (source instanceof Port) {
+ Port port = (Port) source;
+
+ // Rules defined by the Client
+ if (Constants.SERVICE.equals(propertyPath)) {
+ editable = true; // TODO: This method is called only when view opening (good value would be when portHelper.isBehavior(port) && !portHelper.isConnected(port);)
+ } else if (Constants.BEHAVIOR.equals(propertyPath)) {
+ editable = true; // TODO: This method is called only when view opening (good value would be when !(!portHelper.isWired(port) || (portHelper.isWired(port) && !portHelper.isService(port)));)
+ } else if (Constants.CONJUGATED.equals(propertyPath)) {
+ editable = true;
+ } else {
+ editable = super.isFeatureEditable(propertyPath);
+ }
+ }
+
+
+ return editable;
+ }
+
+
/**
- * Get the incmoing interfaces. Don't use getImplementedInterfaces, since it only captures
+ * Get the incoming interfaces. Don't use getImplementedInterfaces, since it only captures
* the interface realization and not the realization relationship.
*
* @return list of required interfaces
*/
protected Interface getInterface(RTMessageKind rtMessageKind) {
Interface result = null;
-
+
Collaboration protocol = (Collaboration) source;
Iterator<DirectedRelationship> relationshipIterator = protocol.getSourceDirectedRelationships().iterator();
while (relationshipIterator.hasNext() && (result == null)) {
DirectedRelationship directedRelation = relationshipIterator.next();
if (directedRelation instanceof Dependency) { // Realization or Usage
- Dependency dependency = (Dependency) directedRelation;
- Iterator<NamedElement> dependencyIterator = dependency.getSuppliers().iterator();
- while (dependencyIterator.hasNext() && (result == null)) {
- NamedElement supplier = dependencyIterator.next();
- if (supplier instanceof Interface) {
- Interface interfaceImpl = (Interface) supplier;
- RTMessageSet rtMessageSet = UMLUtil.getStereotypeApplication(interfaceImpl, RTMessageSet.class);
- if (rtMessageSet != null) {
- if (rtMessageSet.getRtMsgKind() == rtMessageKind) {
- result = (Interface) supplier;
- } // if
- } // if
- } // if
- } // while
- } // if
- } // while
+ result = getInterfaceFromDepencies(rtMessageKind, directedRelation);
+ }
+ }
return result;
}
+ /**
+ * Get the Interface from the dependencies and Kind of Message.
+ *
+ *
+ * @return list of required interfaces
+ */
+ protected Interface getInterfaceFromDepencies(RTMessageKind rtMessageKind, DirectedRelationship directedRelation) {
+ Interface matchingInterface = null;
+ Dependency dependency = (Dependency) directedRelation;
+ Iterator<NamedElement> dependencyIterator = dependency.getSuppliers().iterator();
+
+ while (dependencyIterator.hasNext() && (null == matchingInterface)) {
+ NamedElement supplier = dependencyIterator.next();
+ if (supplier instanceof Interface) {
+ Interface interfaceImpl = (Interface) supplier;
+ RTMessageSet rtMessageSet = UMLUtil.getStereotypeApplication(interfaceImpl, RTMessageSet.class);
+ if ((null != rtMessageSet) && (rtMessageSet.getRtMsgKind() == rtMessageKind)) {
+ matchingInterface = (Interface) supplier;
+
+ }
+ }
+ }
+ return matchingInterface;
+ }
+
+
}
diff --git a/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/modelelement/UMLRTExtModelElementFactory.java b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/modelelement/UMLRTExtModelElementFactory.java
index 384dbb381..02047546e 100644
--- a/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/modelelement/UMLRTExtModelElementFactory.java
+++ b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/modelelement/UMLRTExtModelElementFactory.java
@@ -7,22 +7,28 @@ import org.eclipse.papyrus.uml.properties.modelelement.UMLModelElementFactory;
import org.eclipse.papyrus.views.properties.contexts.DataContextElement;
import org.eclipse.papyrusrt.umlrt.tooling.properties.Activator;
import org.eclipse.uml2.uml.Collaboration;
+import org.eclipse.uml2.uml.Port;
public class UMLRTExtModelElementFactory extends UMLModelElementFactory {
@Override
protected UMLModelElement doCreateFromSource(Object sourceElement, DataContextElement context) {
EObject source = EMFHelper.getEObject(sourceElement);
- if (source == null) {
+ UMLModelElement modelElement = null;
+ if (source != null) {
+ if (source instanceof Collaboration) {
+ modelElement = new UMLRTExtModelElement(source);
+ } else if (source instanceof Port) {
+ modelElement = new UMLRTExtModelElement(source);
+ } else {
+
+ modelElement = super.doCreateFromSource(sourceElement, context);
+ }
+ } else {
Activator.log.warn("Unable to resolve the selected element to an EObject"); //$NON-NLS-1$
- return null;
- }
- if (source instanceof Collaboration) {
- return new UMLRTExtModelElement(source);
- }
- else {
- return super.doCreateFromSource(sourceElement, context);
}
+
+ return modelElement;
}
}
diff --git a/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/modelelement/UMLRTModelElementFactory.java b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/modelelement/UMLRTModelElementFactory.java
new file mode 100644
index 000000000..296085d8f
--- /dev/null
+++ b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/modelelement/UMLRTModelElementFactory.java
@@ -0,0 +1,13 @@
+package org.eclipse.papyrusrt.umlrt.tooling.properties.modelelement;
+
+import org.eclipse.papyrus.uml.properties.modelelement.UMLModelElement;
+import org.eclipse.papyrus.uml.properties.modelelement.UMLModelElementFactory;
+import org.eclipse.papyrus.views.properties.contexts.DataContextElement;
+
+public class UMLRTModelElementFactory extends UMLModelElementFactory {
+ @Override
+ protected UMLModelElement doCreateFromSource(Object source, DataContextElement context) {
+ // TODO Auto-generated method stub
+ return super.doCreateFromSource(source, context);
+ }
+}
diff --git a/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/util/Constants.java b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/util/Constants.java
new file mode 100644
index 000000000..c1e049b18
--- /dev/null
+++ b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/util/Constants.java
@@ -0,0 +1,22 @@
+package org.eclipse.papyrusrt.umlrt.tooling.properties.util;
+
+public final class Constants {
+
+ private Constants() {
+ // Private constructor to avoid instantiation
+ }
+
+ public final static String SERVICE = "isService";// $NON-NLS-0$
+ public final static String WIRED = "isWired";// $NON-NLS-0$
+ public final static String NOTIFICATION = "isNotification";// $NON-NLS-0$
+ public final static String PUBLISH = "isPublish";// $NON-NLS-0$
+ public final static String CONJUGATED = "isConjugated";// $NON-NLS-0$
+ public final static String BEHAVIOR = "isBehavior";// $NON-NLS-0$
+
+ public final static String KIND = "kind";// $NON-NLS-0$
+
+ public final static String UML_RT_STEREOTYPE_QN = "UMLRealTime::RTPort";// $NON-NLS-0$
+
+
+
+}
diff --git a/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/util/RTPortHelper.java b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/util/RTPortHelper.java
new file mode 100644
index 000000000..a612026ba
--- /dev/null
+++ b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/util/RTPortHelper.java
@@ -0,0 +1,63 @@
+package org.eclipse.papyrusrt.umlrt.tooling.properties.util;
+
+import org.eclipse.uml2.uml.Port;
+import org.eclipse.uml2.uml.Stereotype;
+
+public class RTPortHelper {
+ /**
+ * singleton instance
+ */
+ private static RTPortHelper helper;
+
+ /** Singleton constructor */
+ private RTPortHelper() {
+ }
+
+ /**
+ * Returns the singleton instance of this class
+ *
+ * @return the singleton instance.
+ */
+ public static RTPortHelper getInstance() {
+ if (helper == null) {
+ helper = new RTPortHelper();
+ }
+ return helper;
+ }
+
+ public boolean isConnected(Port port) {
+ // TODO To Implements
+ return true;
+ }
+
+ public Stereotype getStereotype(Port port) {
+ return port.getAppliedStereotype(Constants.UML_RT_STEREOTYPE_QN);
+ }
+
+
+ public boolean isWired(Port port) {
+ return (Boolean) port.getValue(getStereotype(port), Constants.WIRED);
+ }
+
+ public boolean isPublish(Port port) {
+ return (Boolean) port.getValue(getStereotype(port), Constants.PUBLISH);
+ }
+
+ public boolean isNotification(Port port) {
+ return (Boolean) port.getValue(getStereotype(port), Constants.NOTIFICATION);
+ }
+
+ public boolean isBehavior(Port port) {
+ return port.isBehavior();
+ }
+
+ public boolean isService(Port port) {
+ return port.isService();
+ }
+
+ public boolean isConjugated(Port port) {
+ return port.isConjugated();
+ }
+
+
+}
diff --git a/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/widgets/PortRTKindEnum.java b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/widgets/PortRTKindEnum.java
new file mode 100644
index 000000000..f24382c12
--- /dev/null
+++ b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/widgets/PortRTKindEnum.java
@@ -0,0 +1,57 @@
+package org.eclipse.papyrusrt.umlrt.tooling.properties.widgets;
+
+public enum PortRTKindEnum implements Comparable<PortRTKindEnum> {
+
+ /**
+ *
+ */
+ EXTERNAL(0, "External Behavior"),
+
+ /**
+ *
+ */
+ INTERNAL(1, "Internal Behavior"),
+
+ /**
+ *
+ */
+ RELAY(2, "Relay"),
+
+ /**
+ *
+ */
+ SAP(3, "SAP"),
+
+ /**
+ *
+ */
+ SPP(4, "SPP");
+
+
+ private final String label;
+ private final int index;
+
+ public String getLabel() {
+
+ return label;
+ }
+
+ public int getIndex() {
+
+ return index;
+ }
+
+
+
+ private PortRTKindEnum(int index, String label) {
+ this.label = label;
+ this.index = index;
+
+ }
+
+ @Override
+ public String toString() {
+ return label;
+ }
+
+}
diff --git a/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/widgets/PortRTKindObservableValue.java b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/widgets/PortRTKindObservableValue.java
new file mode 100644
index 000000000..34c8057f4
--- /dev/null
+++ b/plugins/umlrt/tooling/org.eclipse.papyrusrt.umlrt.tooling.properties/src/org/eclipse/papyrusrt/umlrt/tooling/properties/widgets/PortRTKindObservableValue.java
@@ -0,0 +1,284 @@
+package org.eclipse.papyrusrt.umlrt.tooling.properties.widgets;
+
+import org.eclipse.core.databinding.observable.Diffs;
+import org.eclipse.core.databinding.observable.IObserving;
+import org.eclipse.core.databinding.observable.value.IValueChangeListener;
+import org.eclipse.core.databinding.observable.value.ValueChangeEvent;
+import org.eclipse.core.databinding.observable.value.ValueDiff;
+import org.eclipse.emf.common.command.Command;
+import org.eclipse.emf.common.command.CompoundCommand;
+import org.eclipse.emf.common.notify.Notification;
+import org.eclipse.emf.common.notify.impl.AdapterImpl;
+import org.eclipse.emf.common.util.EList;
+import org.eclipse.emf.ecore.EObject;
+import org.eclipse.emf.ecore.EStructuralFeature;
+import org.eclipse.emf.transaction.RecordingCommand;
+import org.eclipse.emf.transaction.TransactionalEditingDomain;
+import org.eclipse.papyrus.uml.tools.databinding.PapyrusObservableValue;
+import org.eclipse.papyrusrt.umlrt.tooling.properties.util.Constants;
+import org.eclipse.papyrusrt.umlrt.tooling.properties.util.RTPortHelper;
+import org.eclipse.uml2.uml.Element;
+import org.eclipse.uml2.uml.Port;
+import org.eclipse.uml2.uml.Stereotype;
+
+public class PortRTKindObservableValue extends PapyrusObservableValue implements IObserving, IValueChangeListener {
+
+
+
+ private Port port;
+ private Stereotype stereo;
+ private EObject stereotypeApplication;
+
+ private boolean service;
+ private boolean wired;
+ private boolean conjugated;
+ private boolean behavior;
+ private boolean publish;
+ private boolean notification;
+
+
+ RTPortHelper helper = RTPortHelper.getInstance();
+
+
+ /**
+ *
+ * Constructor.
+ *
+ * @param sourceElement
+ */
+ public PortRTKindObservableValue(final Element sourceElement, final TransactionalEditingDomain domain) {
+ super(sourceElement, sourceElement.eContainingFeature(), domain);
+ if (sourceElement instanceof Port) {
+ port = (Port) sourceElement;
+ stereo = port.getAppliedStereotype(Constants.UML_RT_STEREOTYPE_QN);
+ stereotypeApplication = port.getStereotypeApplication(stereo);
+ stereotypeApplication.eAdapters().add(getListener());
+ port.eAdapters().add(getListener());
+ setUMLPropertiesValue();
+ setUMLRTPropertiesValue();
+ }
+
+
+ }
+
+ private AdapterImpl getListener() {
+ return new AdapterImpl() {
+
+ @Override
+ public void notifyChanged(Notification notification) {
+ Object notifier = notification.getNotifier();
+ int type = notification.getEventType();
+ Object feature = notification.getFeature();
+ EList<EStructuralFeature> realTimeFeatureList = stereotypeApplication.eClass().getEStructuralFeatures();
+ EList<EStructuralFeature> umlFeatureList = port.eClass().getEStructuralFeatures();
+
+ if ((notifier == stereotypeApplication) && (type == Notification.SET)) {
+ if (realTimeFeatureList.contains(feature)) {
+ fireDiff(notification);
+ }
+ } else if ((notifier == port) && (type == Notification.SET)) {
+ if (umlFeatureList.contains(feature)) {
+ fireDiff(notification);
+ }
+ }
+ }
+
+ private void fireDiff(Notification notification) {
+ final ValueDiff diff = Diffs.createValueDiff(notification.getOldValue(), notification.getNewValue());
+ getRealm().exec(new Runnable() {
+ @Override
+ public void run() {
+ fireValueChange(diff);
+ }
+ });
+ }
+
+ };
+ }
+
+
+ /**
+ *
+ */
+ private void setUMLRTPropertiesValue() {
+ wired = helper.isWired(port);
+ notification = helper.isNotification(port);
+ publish = helper.isPublish(port);
+
+
+ }
+
+
+
+ /**
+ *
+ */
+ private void setUMLPropertiesValue() {
+ service = helper.isService(port);
+ behavior = helper.isBehavior(port);
+ conjugated = helper.isConjugated(port);
+
+
+
+ }
+
+
+ @Override
+ public Object getValueType() {
+ return PortRTKindEnum.class;
+ }
+
+ @Override
+ public Object getObserved() {
+ return port;
+ }
+
+
+
+ @Override
+ protected Object doGetValue() {
+ PortRTKindEnum kind = PortRTKindEnum.RELAY;
+
+ setUMLPropertiesValue();
+ setUMLRTPropertiesValue();
+
+ if (service && wired && behavior && !publish) {
+ kind = PortRTKindEnum.EXTERNAL;
+ } else if (service && behavior && publish && !wired) {
+ kind = PortRTKindEnum.SPP;
+ } else if (wired && behavior && !service && !publish) {
+ kind = PortRTKindEnum.INTERNAL;
+ } else if (service && wired && !behavior && !publish) {
+ kind = PortRTKindEnum.RELAY;
+ } else if (behavior && !wired && !publish && !service) {
+ kind = PortRTKindEnum.SAP;
+ }
+
+ return kind;
+ }
+
+ @Override
+ protected void doSetValue(Object value) {
+ super.doSetValue(value);
+
+ }
+
+
+
+ @Override
+ public Command getCommand(Object value) {
+ Command command = null;
+ if (value instanceof PortRTKindEnum) {
+ // For Each Kind of Port, set the property accordingly
+ switch ((PortRTKindEnum) value) {
+ case EXTERNAL:
+ command = getCommandForRTPort(true, false, true, true);
+ break;
+ case INTERNAL:
+ command = getCommandForRTPort(true, false, false, true);
+ break;
+ case RELAY:
+ command = getCommandForRTPort(false, false, true, true);
+ break;
+ case SAP:
+ command = getCommandForRTPort(true, false, false, false);
+ break;
+ case SPP:
+ command = getCommandForRTPort(true, true, true, false);
+ break;
+ default:
+ // Relay Port by Default
+ command = getCommandForRTPort(false, false, true, true);
+ break;
+ }
+ }
+ return command;
+ }
+
+ private Command getCommandForRTPort(boolean behavior, boolean publish, boolean service, boolean wired) {
+ CompoundCommand command = new CompoundCommand();
+ command.append(getSetBehaviorCommand(behavior));
+ command.append(getSetPublishCommand(publish));
+ command.append(getSetServiceCommand(service));
+ command.append(getSetWiredCommand(wired));
+ return command;
+ }
+
+ private Command getSetPublishCommand(final boolean publish) {
+ RecordingCommand publishCommand = new RecordingCommand((TransactionalEditingDomain) domain) {
+ @Override
+ protected void doExecute() {
+ port.setValue(stereo, Constants.PUBLISH, publish);
+ }
+
+ @Override
+ public boolean canExecute() {
+ return true;
+ }
+
+ };
+
+ return publishCommand;
+ }
+
+
+
+ private Command getSetWiredCommand(final boolean wired) {
+ RecordingCommand wiredCommand = new RecordingCommand((TransactionalEditingDomain) domain) {
+ @Override
+ protected void doExecute() {
+ port.setValue(stereo, Constants.WIRED, wired);
+ }
+
+ @Override
+ public boolean canExecute() {
+ return true;
+ }
+ };
+
+ return wiredCommand;
+ }
+
+ private Command getSetServiceCommand(final boolean service) {
+ RecordingCommand serviceCommand = new RecordingCommand((TransactionalEditingDomain) domain) {
+ @Override
+ protected void doExecute() {
+ port.setIsService(service);
+ }
+
+ @Override
+ public boolean canExecute() {
+ return true;
+ }
+ };
+
+ return serviceCommand;
+ }
+
+ private Command getSetBehaviorCommand(final boolean behavior) {
+ RecordingCommand behaviorCommand = new RecordingCommand((TransactionalEditingDomain) domain) {
+ @Override
+ protected void doExecute() {
+ port.setIsBehavior(behavior);
+ }
+
+ @Override
+ public boolean canExecute() {
+ return true;
+ }
+ };
+
+ return behaviorCommand;
+ }
+
+ @Override
+ public void handleValueChange(ValueChangeEvent event) {
+ fireChange();
+
+ }
+
+
+
+
+
+}

Back to the top