Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFrancois Le Fevre2017-05-12 13:05:54 +0000
committerNicolas FAUVERGUE2017-06-01 07:19:32 +0000
commit97c7dde3411e673d5bb26f318864979e9b2c9984 (patch)
treec76b0b87362839be2b9257218ef998a3ea7e4811
parentfdf5650b204a1e3a625a08735d91bf1d8df0e098 (diff)
downloadorg.eclipse.papyrus-97c7dde3411e673d5bb26f318864979e9b2c9984.tar.gz
org.eclipse.papyrus-97c7dde3411e673d5bb26f318864979e9b2c9984.tar.xz
org.eclipse.papyrus-97c7dde3411e673d5bb26f318864979e9b2c9984.zip
Bug 516570 - [Toolsmiths][DSML Custo][Table] add the management of table
configuration Actions -adding table data -model generation Tests -generation of a basic plugin Change-Id: Id39ae879ba20a7ceb1753c7919c87bd93dad58b1 Signed-off-by: Francois Le Fevre <francois.le-fevre@cea.fr>
-rw-r--r--plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization.ecore4
-rw-r--r--plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization.genmodel3
-rw-r--r--plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization.notation40
-rw-r--r--plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization.uml6
-rw-r--r--plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization/Customization.ctx33
-rw-r--r--plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization/ui/MultipleTableConfiguration.xwt9
-rw-r--r--plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization/ui/SingleTableConfiguration.xwt2
-rw-r--r--plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/plugin.xml3
-rw-r--r--plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/CustomizationPluginFactory.java9
-rw-r--r--plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/CustomizationPluginPackage.java77
-rw-r--r--plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/TableConfiguration.java59
-rw-r--r--plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/impl/CustomizationPluginFactoryImpl.java11
-rw-r--r--plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/impl/CustomizationPluginPackageImpl.java33
-rw-r--r--plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/impl/TableConfigurationImpl.java172
-rw-r--r--plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/util/CustomizationPluginAdapterFactory.java18
-rw-r--r--plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/util/CustomizationPluginSwitch.java23
-rw-r--r--plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src/org/eclipse/papyrus/toolsmiths/factory/TableExtensionFactory.java89
-rw-r--r--plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src/org/eclipse/papyrus/toolsmiths/messages/Messages.java2
-rw-r--r--plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src/org/eclipse/papyrus/toolsmiths/messages/messages.properties1
19 files changed, 584 insertions, 10 deletions
diff --git a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization.ecore b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization.ecore
index 40874655987..873db120c0b 100644
--- a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization.ecore
+++ b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization.ecore
@@ -56,4 +56,8 @@
</eClassifiers>
<eClassifiers xsi:type="ecore:EClass" name="ConstraintsEnvironment" eSuperTypes="#//FileBasedCustomizableElement"/>
<eClassifiers xsi:type="ecore:EClass" name="PropertyViewEnvironment" eSuperTypes="#//FileBasedCustomizableElement"/>
+ <eClassifiers xsi:type="ecore:EClass" name="TableConfiguration" eSuperTypes="#//FileBasedCustomizableElement">
+ <eStructuralFeatures xsi:type="ecore:EAttribute" name="type" ordered="false" lowerBound="1"
+ eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/>
+ </eClassifiers>
</ecore:EPackage>
diff --git a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization.genmodel b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization.genmodel
index 2bd2dc1f952..1cc2a0dd417 100644
--- a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization.genmodel
+++ b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization.genmodel
@@ -80,5 +80,8 @@
</genClasses>
<genClasses xsi:type="genmodel:GenClass" ecoreClass="Customization.ecore#//ConstraintsEnvironment"/>
<genClasses xsi:type="genmodel:GenClass" ecoreClass="Customization.ecore#//PropertyViewEnvironment"/>
+ <genClasses xsi:type="genmodel:GenClass" ecoreClass="Customization.ecore#//TableConfiguration">
+ <genFeatures xsi:type="genmodel:GenFeature" createChild="false" ecoreFeature="ecore:EAttribute Customization.ecore#//TableConfiguration/type"/>
+ </genClasses>
</genPackages>
</genmodel:GenModel>
diff --git a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization.notation b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization.notation
index 688f814f07f..ccdeb6316eb 100644
--- a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization.notation
+++ b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization.notation
@@ -466,6 +466,36 @@
<element xsi:nil="true"/>
<layoutConstraint xmi:type="notation:Bounds" xmi:id="_HoeqhS_QEeeS8plpp4CJkA" x="200"/>
</children>
+ <children xmi:type="notation:Shape" xmi:id="_u4QwoDcLEeeMbsajGQHQlg" type="Class_Shape">
+ <children xmi:type="notation:DecorationNode" xmi:id="_u4RXsDcLEeeMbsajGQHQlg" type="Class_NameLabel"/>
+ <children xmi:type="notation:DecorationNode" xmi:id="_u4RXsTcLEeeMbsajGQHQlg" type="Class_FloatingNameLabel">
+ <layoutConstraint xmi:type="notation:Location" xmi:id="_u4RXsjcLEeeMbsajGQHQlg" y="15"/>
+ </children>
+ <children xmi:type="notation:BasicCompartment" xmi:id="_u4RXszcLEeeMbsajGQHQlg" type="Class_AttributeCompartment">
+ <children xmi:type="notation:Shape" xmi:id="_xaqb8DcLEeeMbsajGQHQlg" type="Property_ClassAttributeLabel">
+ <element xmi:type="uml:Property" href="Customization.uml#_xZ1VgDcLEeeMbsajGQHQlg"/>
+ <layoutConstraint xmi:type="notation:Location" xmi:id="_xaqb8TcLEeeMbsajGQHQlg"/>
+ </children>
+ <styles xmi:type="notation:TitleStyle" xmi:id="_u4RXtDcLEeeMbsajGQHQlg"/>
+ <styles xmi:type="notation:SortingStyle" xmi:id="_u4RXtTcLEeeMbsajGQHQlg"/>
+ <styles xmi:type="notation:FilteringStyle" xmi:id="_u4RXtjcLEeeMbsajGQHQlg"/>
+ <layoutConstraint xmi:type="notation:Bounds" xmi:id="_u4RXtzcLEeeMbsajGQHQlg"/>
+ </children>
+ <children xmi:type="notation:BasicCompartment" xmi:id="_u4RXuDcLEeeMbsajGQHQlg" type="Class_OperationCompartment">
+ <styles xmi:type="notation:TitleStyle" xmi:id="_u4RXuTcLEeeMbsajGQHQlg"/>
+ <styles xmi:type="notation:SortingStyle" xmi:id="_u4RXujcLEeeMbsajGQHQlg"/>
+ <styles xmi:type="notation:FilteringStyle" xmi:id="_u4RXuzcLEeeMbsajGQHQlg"/>
+ <layoutConstraint xmi:type="notation:Bounds" xmi:id="_u4RXvDcLEeeMbsajGQHQlg"/>
+ </children>
+ <children xmi:type="notation:BasicCompartment" xmi:id="_u4RXvTcLEeeMbsajGQHQlg" type="Class_NestedClassifierCompartment">
+ <styles xmi:type="notation:TitleStyle" xmi:id="_u4RXvjcLEeeMbsajGQHQlg"/>
+ <styles xmi:type="notation:SortingStyle" xmi:id="_u4RXvzcLEeeMbsajGQHQlg"/>
+ <styles xmi:type="notation:FilteringStyle" xmi:id="_u4RXwDcLEeeMbsajGQHQlg"/>
+ <layoutConstraint xmi:type="notation:Bounds" xmi:id="_u4RXwTcLEeeMbsajGQHQlg"/>
+ </children>
+ <element xmi:type="uml:Class" href="Customization.uml#_u4OUYDcLEeeMbsajGQHQlg"/>
+ <layoutConstraint xmi:type="notation:Bounds" xmi:id="_u4QwoTcLEeeMbsajGQHQlg" x="680" y="840"/>
+ </children>
<styles xmi:type="notation:StringValueStyle" xmi:id="_g6StQS8xEeel4ff6F-Bn2A" name="diagram_compatibility_version" stringValue="1.3.0"/>
<styles xmi:type="notation:DiagramStyle" xmi:id="_g6StQi8xEeel4ff6F-Bn2A"/>
<styles xmi:type="style:PapyrusDiagramStyle" xmi:id="_g6StQy8xEeel4ff6F-Bn2A">
@@ -713,4 +743,14 @@
<sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="_McqLMC_QEeeS8plpp4CJkA" id="(0.5581395348837209,0.0)"/>
<targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_McqyQC_QEeeS8plpp4CJkA" id="(0.5555555555555556,1.0)"/>
</edges>
+ <edges xmi:type="notation:Connector" xmi:id="_1DWZ4DcLEeeMbsajGQHQlg" type="Generalization_Edge" source="_u4QwoDcLEeeMbsajGQHQlg" target="_HMD0QC_QEeeS8plpp4CJkA">
+ <children xmi:type="notation:DecorationNode" xmi:id="_1DWZ4zcLEeeMbsajGQHQlg" type="Generalization_StereotypeLabel">
+ <layoutConstraint xmi:type="notation:Location" xmi:id="_1DWZ5DcLEeeMbsajGQHQlg" y="40"/>
+ </children>
+ <styles xmi:type="notation:FontStyle" xmi:id="_1DWZ4TcLEeeMbsajGQHQlg"/>
+ <element xmi:type="uml:Generalization" href="Customization.uml#_1CrrgDcLEeeMbsajGQHQlg"/>
+ <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_1DWZ4jcLEeeMbsajGQHQlg" points="[760, 840, -643984, -643984]$[520, 430, -643984, -643984]"/>
+ <sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="_1EuS4DcLEeeMbsajGQHQlg" id="(0.5673758865248227,0.0)"/>
+ <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_1EuS4TcLEeeMbsajGQHQlg" id="(0.46296296296296297,1.0)"/>
+ </edges>
</notation:Diagram>
diff --git a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization.uml b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization.uml
index 76857cad1e1..7bf2fa97c5c 100644
--- a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization.uml
+++ b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization.uml
@@ -125,6 +125,12 @@
<packagedElement xmi:type="uml:Class" xmi:id="_euAcEy8xEeel4ff6F-Bn2A" name="PropertyViewEnvironment">
<generalization xmi:type="uml:Generalization" xmi:id="_euAcFC8xEeel4ff6F-Bn2A" general="_euAb6S8xEeel4ff6F-Bn2A"/>
</packagedElement>
+ <packagedElement xmi:type="uml:Class" xmi:id="_u4OUYDcLEeeMbsajGQHQlg" name="TableConfiguration">
+ <generalization xmi:type="uml:Generalization" xmi:id="_1CrrgDcLEeeMbsajGQHQlg" general="_euAb6S8xEeel4ff6F-Bn2A"/>
+ <ownedAttribute xmi:type="uml:Property" xmi:id="_xZ1VgDcLEeeMbsajGQHQlg" name="type">
+ <type xmi:type="uml:PrimitiveType" href="pathmap://UML_LIBRARIES/EcorePrimitiveTypes.library.uml#EString"/>
+ </ownedAttribute>
+ </packagedElement>
<profileApplication xmi:type="uml:ProfileApplication" xmi:id="_euAcFS8xEeel4ff6F-Bn2A">
<eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_euAcFi8xEeel4ff6F-Bn2A" source="http://www.eclipse.org/uml2/2.0.0/UML">
<references xmi:type="ecore:EPackage" href="pathmap://UML_PROFILES/Ecore.profile.uml#_z1OFcHjqEdy8S4Cr8Rc_NA"/>
diff --git a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization/Customization.ctx b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization/Customization.ctx
index fb5073ffcd8..6096b9bfa30 100644
--- a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization/Customization.ctx
+++ b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization/Customization.ctx
@@ -28,6 +28,9 @@
<sections xmi:id="_3XOmpjGdEeexFNyA-Izhlg" name="Single UMLModel" sectionFile="ui/SingleUMLModel.xwt">
<widget href="ui/SingleUMLModel.xwt#/"/>
</sections>
+ <sections xmi:id="_BY6HsDcUEeeMbsajGQHQlg" name="Single TableConfiguration" sectionFile="ui/SingleTableConfiguration.xwt">
+ <widget href="ui/SingleTableConfiguration.xwt#/"/>
+ </sections>
<sections xmi:id="_3XOmpzGdEeexFNyA-Izhlg" name="Multiple CustomizationConfiguration" sectionFile="ui/MultipleCustomizationConfiguration.xwt">
<widget href="ui/MultipleCustomizationConfiguration.xwt#/"/>
</sections>
@@ -43,9 +46,6 @@
<sections xmi:id="_3XPNsTGdEeexFNyA-Izhlg" name="Multiple UICustom" sectionFile="ui/MultipleUICustom.xwt">
<widget href="ui/MultipleUICustom.xwt#/"/>
</sections>
- <sections xmi:id="_3XPNsjGdEeexFNyA-Izhlg" name="Multiple ModelTemplate" sectionFile="ui/MultipleModelTemplate.xwt">
- <widget href="ui/MultipleModelTemplate.xwt#/"/>
- </sections>
<sections xmi:id="_3XPNszGdEeexFNyA-Izhlg" name="Multiple Palette" sectionFile="ui/MultiplePalette.xwt">
<widget href="ui/MultiplePalette.xwt#/"/>
</sections>
@@ -55,6 +55,9 @@
<sections xmi:id="_3XPNtTGdEeexFNyA-Izhlg" name="Multiple UMLModel" sectionFile="ui/MultipleUMLModel.xwt">
<widget href="ui/MultipleUMLModel.xwt#/"/>
</sections>
+ <sections xmi:id="_BY6uxTcUEeeMbsajGQHQlg" name="Multiple TableConfiguration" sectionFile="ui/MultipleTableConfiguration.xwt">
+ <widget href="ui/MultipleTableConfiguration.xwt#/"/>
+ </sections>
</tabs>
<views xmi:id="_3XPNtjGdEeexFNyA-Izhlg" name="Single CustomizationConfiguration" sections="_3XN_kjGdEeexFNyA-Izhlg" automaticContext="true" datacontexts="_3XQb_TGdEeexFNyA-Izhlg">
<constraints xsi:type="constraints:SimpleConstraint" xmi:id="_3XPNtzGdEeexFNyA-Izhlg" name="isSingleCustomizationConfiguration">
@@ -119,6 +122,13 @@
<properties xsi:type="constraints:ValueProperty" xmi:id="_3XQb1zGdEeexFNyA-Izhlg" name="className" value="UMLModel"/>
</constraints>
</views>
+ <views xmi:id="_BGwA3TcUEeeMbsajGQHQlg" name="Single TableConfiguration" sections="_BY6HsDcUEeeMbsajGQHQlg" automaticContext="true" datacontexts="_BGwBNTcUEeeMbsajGQHQlg">
+ <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_BGwA3jcUEeeMbsajGQHQlg" name="isSingleTableConfiguration">
+ <constraintType href="ppe:/environment/org.eclipse.papyrus.infra.properties.ui/model/Environment.xmi#//@constraintTypes.0"/>
+ <properties xsi:type="constraints:ValueProperty" xmi:id="_BGwA3zcUEeeMbsajGQHQlg" name="className" value="TableConfiguration"/>
+ <properties xsi:type="constraints:ValueProperty" xmi:id="_BGwA4DcUEeeMbsajGQHQlg" name="nsUri" value="http://www.eclipse.org/papyrus/customization"/>
+ </constraints>
+ </views>
<views xmi:id="_3XQb2DGdEeexFNyA-Izhlg" elementMultiplicity="-1" name="Multiple CustomizationConfiguration" sections="_3XOmpzGdEeexFNyA-Izhlg" automaticContext="true" datacontexts="_3XQb_TGdEeexFNyA-Izhlg">
<constraints xsi:type="constraints:SimpleConstraint" xmi:id="_3XQb2TGdEeexFNyA-Izhlg" name="isMultipleCustomizationConfiguration">
<constraintType href="ppe:/environment/org.eclipse.papyrus.infra.properties.ui/model/Environment.xmi#//@constraintTypes.0"/>
@@ -154,13 +164,6 @@
<properties xsi:type="constraints:ValueProperty" xmi:id="_3XQb6zGdEeexFNyA-Izhlg" name="nsUri" value="http://www.eclipse.org/papyrus/customization"/>
</constraints>
</views>
- <views xmi:id="_3XQb7DGdEeexFNyA-Izhlg" elementMultiplicity="-1" name="Multiple ModelTemplate" sections="_3XPNsjGdEeexFNyA-Izhlg" automaticContext="true" datacontexts="_3XQcBjGdEeexFNyA-Izhlg">
- <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_3XQb7TGdEeexFNyA-Izhlg" name="isMultipleModelTemplate">
- <constraintType href="ppe:/environment/org.eclipse.papyrus.infra.properties.ui/model/Environment.xmi#//@constraintTypes.0"/>
- <properties xsi:type="constraints:ValueProperty" xmi:id="_3XQb7jGdEeexFNyA-Izhlg" name="nsUri" value="http://www.eclipse.org/papyrus/customization"/>
- <properties xsi:type="constraints:ValueProperty" xmi:id="_3XQb7zGdEeexFNyA-Izhlg" name="className" value="ModelTemplate"/>
- </constraints>
- </views>
<views xmi:id="_3XQb8DGdEeexFNyA-Izhlg" elementMultiplicity="-1" name="Multiple Palette" sections="_3XPNszGdEeexFNyA-Izhlg" automaticContext="true" datacontexts="_3XQcCjGdEeexFNyA-Izhlg">
<constraints xsi:type="constraints:SimpleConstraint" xmi:id="_3XQb8TGdEeexFNyA-Izhlg" name="isMultiplePalette">
<constraintType href="ppe:/environment/org.eclipse.papyrus.infra.properties.ui/model/Environment.xmi#//@constraintTypes.0"/>
@@ -182,6 +185,13 @@
<properties xsi:type="constraints:ValueProperty" xmi:id="_3XQb-zGdEeexFNyA-Izhlg" name="nsUri" value="http://www.eclipse.org/papyrus/customization"/>
</constraints>
</views>
+ <views xmi:id="_BGwBDTcUEeeMbsajGQHQlg" elementMultiplicity="-1" name="Multiple TableConfiguration" sections="_BY6uxTcUEeeMbsajGQHQlg" automaticContext="true" datacontexts="_BGwBNTcUEeeMbsajGQHQlg">
+ <constraints xsi:type="constraints:SimpleConstraint" xmi:id="_BGwBDjcUEeeMbsajGQHQlg" name="isMultipleTableConfiguration">
+ <constraintType href="ppe:/environment/org.eclipse.papyrus.infra.properties.ui/model/Environment.xmi#//@constraintTypes.0"/>
+ <properties xsi:type="constraints:ValueProperty" xmi:id="_BGwBDzcUEeeMbsajGQHQlg" name="className" value="TableConfiguration"/>
+ <properties xsi:type="constraints:ValueProperty" xmi:id="_BGwBEDcUEeeMbsajGQHQlg" name="nsUri" value="http://www.eclipse.org/papyrus/customization"/>
+ </constraints>
+ </views>
<dataContexts xmi:id="_3XQb_DGdEeexFNyA-Izhlg" name="customization" label="customization">
<elements xmi:id="_3XQb_TGdEeexFNyA-Izhlg" name="CustomizationConfiguration">
<properties xmi:id="_3XQb_jGdEeexFNyA-Izhlg" name="plugin"/>
@@ -214,6 +224,9 @@
<properties xmi:id="_3XQcFDGdEeexFNyA-Izhlg" name="description"/>
<properties xmi:id="_3XQcFTGdEeexFNyA-Izhlg" name="provider"/>
</elements>
+ <elements xmi:id="_BGwBNTcUEeeMbsajGQHQlg" name="TableConfiguration">
+ <properties xmi:id="_BGwBNjcUEeeMbsajGQHQlg" name="type"/>
+ </elements>
<modelElementFactory href="ppe:/environment/org.eclipse.papyrus.toolsmiths/models/Environment.xmi#//@modelElementFactories.0"/>
</dataContexts>
</contexts:Context>
diff --git a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization/ui/MultipleTableConfiguration.xwt b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization/ui/MultipleTableConfiguration.xwt
new file mode 100644
index 00000000000..e29bdbb8542
--- /dev/null
+++ b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization/ui/MultipleTableConfiguration.xwt
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<Composite xmlns="http://www.eclipse.org/xwt/presentation"
+ xmlns:j="clr-namespace:java.lang"
+ xmlns:ppel="clr-namespace:org.eclipse.papyrus.infra.properties.ui.widgets.layout"
+ xmlns:x="http://www.eclipse.org/xwt">
+ <Composite.layout>
+ <ppel:PropertiesLayout></ppel:PropertiesLayout>
+ </Composite.layout>
+</Composite> \ No newline at end of file
diff --git a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization/ui/SingleTableConfiguration.xwt b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization/ui/SingleTableConfiguration.xwt
new file mode 100644
index 00000000000..c462d0f3c0e
--- /dev/null
+++ b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/models/Customization/ui/SingleTableConfiguration.xwt
@@ -0,0 +1,2 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<Composite xmlns="http://www.eclipse.org/xwt/presentation" xmlns:j="clr-namespace:java.lang" xmlns:ppe="clr-namespace:org.eclipse.papyrus.infra.properties.ui.widgets" xmlns:ppel="clr-namespace:org.eclipse.papyrus.infra.properties.ui.widgets.layout" xmlns:x="http://www.eclipse.org/xwt"><Composite.layout><ppel:PropertiesLayout></ppel:PropertiesLayout></Composite.layout><Composite><Composite.layout><ppel:PropertiesLayout numColumns="1"></ppel:PropertiesLayout></Composite.layout><ppe:StringFileSelector input="{Binding}" property="customization:FileBasedCustomizableElement:file"></ppe:StringFileSelector><ppe:StringEditor input="{Binding}" property="customization:TableConfiguration:type"></ppe:StringEditor></Composite></Composite> \ No newline at end of file
diff --git a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/plugin.xml b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/plugin.xml
index 132150137a3..3d7c2bae3ce 100644
--- a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/plugin.xml
+++ b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/plugin.xml
@@ -59,6 +59,9 @@
factory="org.eclipse.papyrus.toolsmiths.factory.UICustomExtensionFactory">
</factory>
<factory
+ factory="org.eclipse.papyrus.toolsmiths.factory.TableExtensionFactory">
+ </factory>
+ <factory
factory="org.eclipse.papyrus.toolsmiths.factory.UMLModelExtensionFactory">
</factory>
<factory
diff --git a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/CustomizationPluginFactory.java b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/CustomizationPluginFactory.java
index 2a5ba430ff9..7f2419b87d8 100644
--- a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/CustomizationPluginFactory.java
+++ b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/CustomizationPluginFactory.java
@@ -113,6 +113,15 @@ public interface CustomizationPluginFactory extends EFactory {
PropertyViewEnvironment createPropertyViewEnvironment();
/**
+ * Returns a new object of class '<em>Table Configuration</em>'.
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @return a new object of class '<em>Table Configuration</em>'.
+ * @generated
+ */
+ TableConfiguration createTableConfiguration();
+
+ /**
* Returns the package supported by this factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
diff --git a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/CustomizationPluginPackage.java b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/CustomizationPluginPackage.java
index 65f5a53c3ab..30dbe81a9c8 100644
--- a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/CustomizationPluginPackage.java
+++ b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/CustomizationPluginPackage.java
@@ -564,6 +564,44 @@ public interface CustomizationPluginPackage extends EPackage {
/**
+ * The meta object id for the '{@link org.eclipse.papyrus.toolsmiths.model.customizationplugin.impl.TableConfigurationImpl <em>Table Configuration</em>}' class.
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @see org.eclipse.papyrus.toolsmiths.model.customizationplugin.impl.TableConfigurationImpl
+ * @see org.eclipse.papyrus.toolsmiths.model.customizationplugin.impl.CustomizationPluginPackageImpl#getTableConfiguration()
+ * @generated
+ */
+ int TABLE_CONFIGURATION = 11;
+
+ /**
+ * The feature id for the '<em><b>File</b></em>' attribute.
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @generated
+ * @ordered
+ */
+ int TABLE_CONFIGURATION__FILE = FILE_BASED_CUSTOMIZABLE_ELEMENT__FILE;
+
+ /**
+ * The feature id for the '<em><b>Type</b></em>' attribute.
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @generated
+ * @ordered
+ */
+ int TABLE_CONFIGURATION__TYPE = FILE_BASED_CUSTOMIZABLE_ELEMENT_FEATURE_COUNT + 0;
+
+ /**
+ * The number of structural features of the '<em>Table Configuration</em>' class.
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @generated
+ * @ordered
+ */
+ int TABLE_CONFIGURATION_FEATURE_COUNT = FILE_BASED_CUSTOMIZABLE_ELEMENT_FEATURE_COUNT + 1;
+
+
+ /**
* Returns the meta object for class '{@link org.eclipse.papyrus.toolsmiths.model.customizationplugin.CustomizationConfiguration <em>Customization Configuration</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
@@ -938,6 +976,27 @@ public interface CustomizationPluginPackage extends EPackage {
EClass getPropertyViewEnvironment();
/**
+ * Returns the meta object for class '{@link org.eclipse.papyrus.toolsmiths.model.customizationplugin.TableConfiguration <em>Table Configuration</em>}'.
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @return the meta object for class '<em>Table Configuration</em>'.
+ * @see org.eclipse.papyrus.toolsmiths.model.customizationplugin.TableConfiguration
+ * @generated
+ */
+ EClass getTableConfiguration();
+
+ /**
+ * Returns the meta object for the attribute '{@link org.eclipse.papyrus.toolsmiths.model.customizationplugin.TableConfiguration#getType <em>Type</em>}'.
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @return the meta object for the attribute '<em>Type</em>'.
+ * @see org.eclipse.papyrus.toolsmiths.model.customizationplugin.TableConfiguration#getType()
+ * @see #getTableConfiguration()
+ * @generated
+ */
+ EAttribute getTableConfiguration_Type();
+
+ /**
* Returns the factory that creates the instances of the model.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
@@ -1261,6 +1320,24 @@ public interface CustomizationPluginPackage extends EPackage {
*/
EClass PROPERTY_VIEW_ENVIRONMENT = eINSTANCE.getPropertyViewEnvironment();
+ /**
+ * The meta object literal for the '{@link org.eclipse.papyrus.toolsmiths.model.customizationplugin.impl.TableConfigurationImpl <em>Table Configuration</em>}' class.
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @see org.eclipse.papyrus.toolsmiths.model.customizationplugin.impl.TableConfigurationImpl
+ * @see org.eclipse.papyrus.toolsmiths.model.customizationplugin.impl.CustomizationPluginPackageImpl#getTableConfiguration()
+ * @generated
+ */
+ EClass TABLE_CONFIGURATION = eINSTANCE.getTableConfiguration();
+
+ /**
+ * The meta object literal for the '<em><b>Type</b></em>' attribute feature.
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @generated
+ */
+ EAttribute TABLE_CONFIGURATION__TYPE = eINSTANCE.getTableConfiguration_Type();
+
}
} //CustomizationPluginPackage
diff --git a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/TableConfiguration.java b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/TableConfiguration.java
new file mode 100644
index 00000000000..c0eae019cee
--- /dev/null
+++ b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/TableConfiguration.java
@@ -0,0 +1,59 @@
+/**
+ * Copyright (c) 2012 CEA LIST.
+ *
+ * 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:
+ * Camille Letavernier (CEA LIST) camille.letavernier@cea.fr - Initial API and implementation
+ *
+ */
+package org.eclipse.papyrus.toolsmiths.model.customizationplugin;
+
+
+/**
+ * <!-- begin-user-doc -->
+ * A representation of the model object '<em><b>Table Configuration</b></em>'.
+ * <!-- end-user-doc -->
+ *
+ * <p>
+ * The following features are supported:
+ * </p>
+ * <ul>
+ * <li>{@link org.eclipse.papyrus.toolsmiths.model.customizationplugin.TableConfiguration#getType <em>Type</em>}</li>
+ * </ul>
+ *
+ * @see org.eclipse.papyrus.toolsmiths.model.customizationplugin.CustomizationPluginPackage#getTableConfiguration()
+ * @model
+ * @generated
+ */
+public interface TableConfiguration extends FileBasedCustomizableElement {
+ /**
+ * Returns the value of the '<em><b>Type</b></em>' attribute.
+ * <!-- begin-user-doc -->
+ * <p>
+ * If the meaning of the '<em>Type</em>' attribute isn't clear,
+ * there really should be more of a description here...
+ * </p>
+ * <!-- end-user-doc -->
+ * @return the value of the '<em>Type</em>' attribute.
+ * @see #setType(String)
+ * @see org.eclipse.papyrus.toolsmiths.model.customizationplugin.CustomizationPluginPackage#getTableConfiguration_Type()
+ * @model required="true" ordered="false"
+ * @generated
+ */
+ String getType();
+
+ /**
+ * Sets the value of the '{@link org.eclipse.papyrus.toolsmiths.model.customizationplugin.TableConfiguration#getType <em>Type</em>}' attribute.
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @param value the new value of the '<em>Type</em>' attribute.
+ * @see #getType()
+ * @generated
+ */
+ void setType(String value);
+
+} // TableConfiguration
diff --git a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/impl/CustomizationPluginFactoryImpl.java b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/impl/CustomizationPluginFactoryImpl.java
index 17540dbcf8d..c2410be38e7 100644
--- a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/impl/CustomizationPluginFactoryImpl.java
+++ b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/impl/CustomizationPluginFactoryImpl.java
@@ -75,6 +75,7 @@ public class CustomizationPluginFactoryImpl extends EFactoryImpl implements Cust
case CustomizationPluginPackage.UML_MODEL: return createUMLModel();
case CustomizationPluginPackage.CONSTRAINTS_ENVIRONMENT: return createConstraintsEnvironment();
case CustomizationPluginPackage.PROPERTY_VIEW_ENVIRONMENT: return createPropertyViewEnvironment();
+ case CustomizationPluginPackage.TABLE_CONFIGURATION: return createTableConfiguration();
default:
throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); //$NON-NLS-1$ //$NON-NLS-2$
}
@@ -175,6 +176,16 @@ public class CustomizationPluginFactoryImpl extends EFactoryImpl implements Cust
* <!-- end-user-doc -->
* @generated
*/
+ public TableConfiguration createTableConfiguration() {
+ TableConfigurationImpl tableConfiguration = new TableConfigurationImpl();
+ return tableConfiguration;
+ }
+
+ /**
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @generated
+ */
public CustomizationPluginPackage getCustomizationPluginPackage() {
return (CustomizationPluginPackage)getEPackage();
}
diff --git a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/impl/CustomizationPluginPackageImpl.java b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/impl/CustomizationPluginPackageImpl.java
index ed6afe9304d..ecb669a5a96 100644
--- a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/impl/CustomizationPluginPackageImpl.java
+++ b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/impl/CustomizationPluginPackageImpl.java
@@ -30,6 +30,7 @@ import org.eclipse.papyrus.toolsmiths.model.customizationplugin.Palette;
import org.eclipse.papyrus.toolsmiths.model.customizationplugin.Profile;
import org.eclipse.papyrus.toolsmiths.model.customizationplugin.PropertyView;
import org.eclipse.papyrus.toolsmiths.model.customizationplugin.PropertyViewEnvironment;
+import org.eclipse.papyrus.toolsmiths.model.customizationplugin.TableConfiguration;
import org.eclipse.papyrus.toolsmiths.model.customizationplugin.UICustom;
import org.eclipse.papyrus.toolsmiths.model.customizationplugin.UMLModel;
@@ -118,6 +119,13 @@ public class CustomizationPluginPackageImpl extends EPackageImpl implements Cust
private EClass propertyViewEnvironmentEClass = null;
/**
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @generated
+ */
+ private EClass tableConfigurationEClass = null;
+
+ /**
* Creates an instance of the model <b>Package</b>, registered with
* {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package
* package URI value.
@@ -498,6 +506,24 @@ public class CustomizationPluginPackageImpl extends EPackageImpl implements Cust
* <!-- end-user-doc -->
* @generated
*/
+ public EClass getTableConfiguration() {
+ return tableConfigurationEClass;
+ }
+
+ /**
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @generated
+ */
+ public EAttribute getTableConfiguration_Type() {
+ return (EAttribute)tableConfigurationEClass.getEStructuralFeatures().get(0);
+ }
+
+ /**
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @generated
+ */
public CustomizationPluginFactory getCustomizationPluginFactory() {
return (CustomizationPluginFactory)getEFactoryInstance();
}
@@ -566,6 +592,9 @@ public class CustomizationPluginPackageImpl extends EPackageImpl implements Cust
constraintsEnvironmentEClass = createEClass(CONSTRAINTS_ENVIRONMENT);
propertyViewEnvironmentEClass = createEClass(PROPERTY_VIEW_ENVIRONMENT);
+
+ tableConfigurationEClass = createEClass(TABLE_CONFIGURATION);
+ createEAttribute(tableConfigurationEClass, TABLE_CONFIGURATION__TYPE);
}
/**
@@ -605,6 +634,7 @@ public class CustomizationPluginPackageImpl extends EPackageImpl implements Cust
umlModelEClass.getESuperTypes().add(this.getFileBasedCustomizableElement());
constraintsEnvironmentEClass.getESuperTypes().add(this.getFileBasedCustomizableElement());
propertyViewEnvironmentEClass.getESuperTypes().add(this.getFileBasedCustomizableElement());
+ tableConfigurationEClass.getESuperTypes().add(this.getFileBasedCustomizableElement());
// Initialize classes and features; add operations and parameters
initEClass(customizationConfigurationEClass, CustomizationConfiguration.class, "CustomizationConfiguration", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); //$NON-NLS-1$
@@ -653,6 +683,9 @@ public class CustomizationPluginPackageImpl extends EPackageImpl implements Cust
initEClass(propertyViewEnvironmentEClass, PropertyViewEnvironment.class, "PropertyViewEnvironment", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); //$NON-NLS-1$
+ initEClass(tableConfigurationEClass, TableConfiguration.class, "TableConfiguration", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); //$NON-NLS-1$
+ initEAttribute(getTableConfiguration_Type(), ecorePackage.getEString(), "type", null, 1, 1, TableConfiguration.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); //$NON-NLS-1$
+
// Create resource
createResource(eNS_URI);
}
diff --git a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/impl/TableConfigurationImpl.java b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/impl/TableConfigurationImpl.java
new file mode 100644
index 00000000000..645912a53a9
--- /dev/null
+++ b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/impl/TableConfigurationImpl.java
@@ -0,0 +1,172 @@
+/**
+ * Copyright (c) 2012 CEA LIST.
+ *
+ * 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:
+ * Camille Letavernier (CEA LIST) camille.letavernier@cea.fr - Initial API and implementation
+ *
+ */
+package org.eclipse.papyrus.toolsmiths.model.customizationplugin.impl;
+
+import org.eclipse.emf.common.notify.Notification;
+
+import org.eclipse.emf.ecore.EClass;
+
+import org.eclipse.emf.ecore.impl.ENotificationImpl;
+
+import org.eclipse.papyrus.toolsmiths.model.customizationplugin.CustomizationPluginPackage;
+import org.eclipse.papyrus.toolsmiths.model.customizationplugin.TableConfiguration;
+
+/**
+ * <!-- begin-user-doc -->
+ * An implementation of the model object '<em><b>Table Configuration</b></em>'.
+ * <!-- end-user-doc -->
+ * <p>
+ * The following features are implemented:
+ * </p>
+ * <ul>
+ * <li>{@link org.eclipse.papyrus.toolsmiths.model.customizationplugin.impl.TableConfigurationImpl#getType <em>Type</em>}</li>
+ * </ul>
+ *
+ * @generated
+ */
+public class TableConfigurationImpl extends FileBasedCustomizableElementImpl implements TableConfiguration {
+ /**
+ * The default value of the '{@link #getType() <em>Type</em>}' attribute.
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @see #getType()
+ * @generated
+ * @ordered
+ */
+ protected static final String TYPE_EDEFAULT = null;
+
+ /**
+ * The cached value of the '{@link #getType() <em>Type</em>}' attribute.
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @see #getType()
+ * @generated
+ * @ordered
+ */
+ protected String type = TYPE_EDEFAULT;
+
+ /**
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @generated
+ */
+ protected TableConfigurationImpl() {
+ super();
+ }
+
+ /**
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @generated
+ */
+ @Override
+ protected EClass eStaticClass() {
+ return CustomizationPluginPackage.Literals.TABLE_CONFIGURATION;
+ }
+
+ /**
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @generated
+ */
+ public String getType() {
+ return type;
+ }
+
+ /**
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @generated
+ */
+ public void setType(String newType) {
+ String oldType = type;
+ type = newType;
+ if (eNotificationRequired())
+ eNotify(new ENotificationImpl(this, Notification.SET, CustomizationPluginPackage.TABLE_CONFIGURATION__TYPE, oldType, type));
+ }
+
+ /**
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @generated
+ */
+ @Override
+ public Object eGet(int featureID, boolean resolve, boolean coreType) {
+ switch (featureID) {
+ case CustomizationPluginPackage.TABLE_CONFIGURATION__TYPE:
+ return getType();
+ }
+ return super.eGet(featureID, resolve, coreType);
+ }
+
+ /**
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @generated
+ */
+ @Override
+ public void eSet(int featureID, Object newValue) {
+ switch (featureID) {
+ case CustomizationPluginPackage.TABLE_CONFIGURATION__TYPE:
+ setType((String)newValue);
+ return;
+ }
+ super.eSet(featureID, newValue);
+ }
+
+ /**
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @generated
+ */
+ @Override
+ public void eUnset(int featureID) {
+ switch (featureID) {
+ case CustomizationPluginPackage.TABLE_CONFIGURATION__TYPE:
+ setType(TYPE_EDEFAULT);
+ return;
+ }
+ super.eUnset(featureID);
+ }
+
+ /**
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @generated
+ */
+ @Override
+ public boolean eIsSet(int featureID) {
+ switch (featureID) {
+ case CustomizationPluginPackage.TABLE_CONFIGURATION__TYPE:
+ return TYPE_EDEFAULT == null ? type != null : !TYPE_EDEFAULT.equals(type);
+ }
+ return super.eIsSet(featureID);
+ }
+
+ /**
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @generated
+ */
+ @Override
+ public String toString() {
+ if (eIsProxy()) return super.toString();
+
+ StringBuffer result = new StringBuffer(super.toString());
+ result.append(" (type: "); //$NON-NLS-1$
+ result.append(type);
+ result.append(')');
+ return result.toString();
+ }
+
+} //TableConfigurationImpl
diff --git a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/util/CustomizationPluginAdapterFactory.java b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/util/CustomizationPluginAdapterFactory.java
index d0ad5f78cf8..999833b089d 100644
--- a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/util/CustomizationPluginAdapterFactory.java
+++ b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/util/CustomizationPluginAdapterFactory.java
@@ -122,6 +122,10 @@ public class CustomizationPluginAdapterFactory extends AdapterFactoryImpl {
return createPropertyViewEnvironmentAdapter();
}
@Override
+ public Adapter caseTableConfiguration(TableConfiguration object) {
+ return createTableConfigurationAdapter();
+ }
+ @Override
public Adapter defaultCase(EObject object) {
return createEObjectAdapter();
}
@@ -296,6 +300,20 @@ public class CustomizationPluginAdapterFactory extends AdapterFactoryImpl {
}
/**
+ * Creates a new adapter for an object of class '{@link org.eclipse.papyrus.toolsmiths.model.customizationplugin.TableConfiguration <em>Table Configuration</em>}'.
+ * <!-- begin-user-doc -->
+ * This default implementation returns null so that we can easily ignore cases;
+ * it's useful to ignore a case when inheritance will catch all the cases anyway.
+ * <!-- end-user-doc -->
+ * @return the new adapter.
+ * @see org.eclipse.papyrus.toolsmiths.model.customizationplugin.TableConfiguration
+ * @generated
+ */
+ public Adapter createTableConfigurationAdapter() {
+ return null;
+ }
+
+ /**
* Creates a new adapter for the default case.
* <!-- begin-user-doc -->
* This default implementation returns null.
diff --git a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/util/CustomizationPluginSwitch.java b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/util/CustomizationPluginSwitch.java
index 0fed125e151..dbc7743c9db 100644
--- a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/util/CustomizationPluginSwitch.java
+++ b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src-gen/org/eclipse/papyrus/toolsmiths/model/customizationplugin/util/CustomizationPluginSwitch.java
@@ -159,6 +159,14 @@ public class CustomizationPluginSwitch<T> extends Switch<T> {
if (result == null) result = defaultCase(theEObject);
return result;
}
+ case CustomizationPluginPackage.TABLE_CONFIGURATION: {
+ TableConfiguration tableConfiguration = (TableConfiguration)theEObject;
+ T result = caseTableConfiguration(tableConfiguration);
+ if (result == null) result = caseFileBasedCustomizableElement(tableConfiguration);
+ if (result == null) result = caseCustomizableElement(tableConfiguration);
+ if (result == null) result = defaultCase(theEObject);
+ return result;
+ }
default: return defaultCase(theEObject);
}
}
@@ -329,6 +337,21 @@ public class CustomizationPluginSwitch<T> extends Switch<T> {
}
/**
+ * Returns the result of interpreting the object as an instance of '<em>Table Configuration</em>'.
+ * <!-- begin-user-doc -->
+ * This implementation returns null;
+ * returning a non-null result will terminate the switch.
+ * <!-- end-user-doc -->
+ * @param object the target of the switch.
+ * @return the result of interpreting the object as an instance of '<em>Table Configuration</em>'.
+ * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
+ * @generated
+ */
+ public T caseTableConfiguration(TableConfiguration object) {
+ return null;
+ }
+
+ /**
* Returns the result of interpreting the object as an instance of '<em>EObject</em>'.
* <!-- begin-user-doc -->
* This implementation returns null;
diff --git a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src/org/eclipse/papyrus/toolsmiths/factory/TableExtensionFactory.java b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src/org/eclipse/papyrus/toolsmiths/factory/TableExtensionFactory.java
new file mode 100644
index 00000000000..4816b6b76f9
--- /dev/null
+++ b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src/org/eclipse/papyrus/toolsmiths/factory/TableExtensionFactory.java
@@ -0,0 +1,89 @@
+/*****************************************************************************
+ * Copyright (c) 2017 CEA LIST.
+ *
+ * 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:
+ * Francois Le Fevre (CEA LIST) francois.le-fevre@cea.fr - Initial API and implementation
+ *****************************************************************************/
+package org.eclipse.papyrus.toolsmiths.factory;
+
+import java.io.File;
+import java.io.FileNotFoundException;
+import java.io.IOException;
+
+import org.eclipse.emf.ecore.EClass;
+import org.eclipse.papyrus.eclipse.project.editors.interfaces.IPluginEditor;
+import org.eclipse.papyrus.toolsmiths.messages.Messages;
+import org.eclipse.papyrus.toolsmiths.model.customizationplugin.CustomizableElement;
+import org.eclipse.papyrus.toolsmiths.model.customizationplugin.CustomizationPluginPackage;
+import org.eclipse.papyrus.toolsmiths.model.customizationplugin.FileBasedCustomizableElement;
+import org.eclipse.papyrus.toolsmiths.model.customizationplugin.TableConfiguration;
+import org.w3c.dom.Element;
+
+
+/**
+ * Toolsmiths DSML Configurator Extension to manage the Table configuration file
+ * @author Francois Le Fevre
+ *
+ */
+public class TableExtensionFactory extends FileBasedExtensionFactory {
+
+ /**
+ * the folder name where will be gather all tabel configuration files
+ */
+ public static final String TABLE_ROOT_FOLDER = new String("table"); //$NON-NLS-1$
+
+
+ public TableExtensionFactory() {
+ super(Messages.TableFactory_Table, "org.eclipse.papyrus.infra.nattable.configuration", "file", "configuration", true); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ }
+
+ @Override
+ public void addElement(CustomizableElement element, IPluginEditor editor) {
+ super.addElement(element, editor);
+
+ editor.addDependency("org.eclipse.papyrus.infra.nattable"); //$NON-NLS-1$
+ }
+
+ @Override
+ protected Element createExtension(FileBasedCustomizableElement customizableElement, IPluginEditor editor) {
+ Element extension = super.createExtension(customizableElement, editor);
+ if (customizableElement instanceof TableConfiguration) {
+ TableConfiguration element = (TableConfiguration) customizableElement;
+
+ if (element.getType() != null) {
+ extension.setAttribute("type", element.getType()); //$NON-NLS-1$
+ }
+
+ }
+
+ return extension;
+ }
+
+ @Override
+ protected String getTargetPath(FileBasedCustomizableElement element) {
+ return getFilePath(element.getFile()); //$NON-NLS-1$
+ }
+
+ /**
+ * Return the full file path where will be written the tabel configuration
+ * @param file the file name
+ * @return
+ */
+ protected String getFilePath(String file) {
+ return File.separator+TABLE_ROOT_FOLDER+File.separator + getFileName(file);
+ }
+
+ public EClass getCustomizableElementClass() {
+ return CustomizationPluginPackage.eINSTANCE.getTableConfiguration();
+ }
+
+ @Override
+ protected void copyFile(FileBasedCustomizableElement element, IPluginEditor editor) throws FileNotFoundException, IOException {
+ copyFile(element.getFile(), getFilePath(((TableConfiguration)element).getFile()), editor);
+ }
+}
diff --git a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src/org/eclipse/papyrus/toolsmiths/messages/Messages.java b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src/org/eclipse/papyrus/toolsmiths/messages/Messages.java
index 134f6c4179d..7899103fe02 100644
--- a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src/org/eclipse/papyrus/toolsmiths/messages/Messages.java
+++ b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src/org/eclipse/papyrus/toolsmiths/messages/Messages.java
@@ -17,6 +17,8 @@ public class Messages extends NLS {
private static final String BUNDLE_NAME = "org.eclipse.papyrus.toolsmiths.messages.messages"; //$NON-NLS-1$
+ public static String TableFactory_Table;
+
public static String PaletteFactory_Palette;
public static String UICustomExtensionFactory_UICustom;
diff --git a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src/org/eclipse/papyrus/toolsmiths/messages/messages.properties b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src/org/eclipse/papyrus/toolsmiths/messages/messages.properties
index d865074094b..fd3590c4f35 100644
--- a/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src/org/eclipse/papyrus/toolsmiths/messages/messages.properties
+++ b/plugins/toolsmiths/org.eclipse.papyrus.toolsmiths/src/org/eclipse/papyrus/toolsmiths/messages/messages.properties
@@ -12,3 +12,4 @@ CreateNewCustomizationPluginWizard_CustomizationPlugin=DSML configuration plug-i
CustomizationPage_Customization=Customization
EnvironmentExtensionFactory_PropertyViewEnvironment=Property view Environment
PaletteFactory_Palette=Palette
+TableFactory_Table=Table

Back to the top